Measurements made in the 18th century to determine how old the Earth is were based on the rate of the Earth's cooling. The results of these computations vastly underestimated the age of the Earth to be in the hundreds of thousands of years.
Later guesses by esteemed scientists like Charles Darwin (who proposed 306.7 million years) and Lord Kelvin (who made several erroneous proposals spanning hundreds of millions of years) were only moderate improvements.
The ability to accurately date our planet — which formed out of debris left behind by the birth of the sun — developed with the understanding of radioactive decay. Radioactive substances release subatomic particles at a very steady rate. Sometimes the age of an object can be determined by comparing present amounts of a radioactive substance with the supposed original amount in the object. Uranium is a particularly well-understood, naturally radioactive element.
By measuring lead to uranium ratios in ancient rock samples, in 1953 scientists deftly put Earth's age at 4.5 to 4.6 billion years, an estimate that stands today.