The age of an ice core is determined by a variety of techniques:
Counting the annual layers (left) marked by differences in 18O, similar to counting tree rings to determine the age of the tree.
Calibration by known historic events like volcanic eruptions and weapons testing.
Dating the gas captured in the ice. This is done by retrieving the trapped gas and using either 14C or 36Cl dating techniques to determine the age of the gas.