This is how carbon dating works: Carbon is a naturally abundant element found in the atmosphere, in the earth, in the oceans, and in every living creature.C-12 is by far the most common isotope, while only about one in a trillion carbon atoms is C-14.Plants and animals naturally incorporate both the abundant C-12 isotope and the much rarer radiocarbon isotope into their tissues in about the same proportions as the two occur in the atmosphere during their lifetimes.
It takes about 5,730 years for half of a sample of radiocarbon to decay back into nitrogen.
Archaeologists have long used carbon-14 dating (also known as radiocarbon dating) to estimate the age of certain objects.
Traditional radiocarbon dating is applied to organic remains between 500 and 50,000 years old and exploits the fact that trace amounts of radioactive carbon are found in the natural environment.
And so it's kind of a record of the atmosphere up to 10,000 years. Those are the speleothems that are coming from the top of the cave.
If you want to go even further back, you can look at cave deposits, and the fancy word for these cave deposits are speleothems. But the reason why these are useful is these are formed by calcium carbonate, so they have carbon in them, and slowly over, really, tens of thousands of years, the water in the cave deposits that calcium carbonate.