When ice is formed, CO2 levels in the air at that time are trapped in the ice particles. When the ice is later melted down in laboratories, scientists can tell the C02 levels that were present in the atmosphere when that ice was formed. Because ice in the glaciers is formed during the winter, and then melts during the summer, when you cut a cross section into the glaciers in Greenland or Antarctica, you see a series of stripes -- one stripe representing each year, with the current year on the top. Scientists can tell CO2 levels going back many thousands of years by counting the levels down the glacier and testing the ice. This is not a disputed science.
Based on that science, this is what they know: