Earth and Mars were formed from inner Solar System material https://www.mpg.de/18089179/earth-and-mars-were-formed-from-inner-solar-system-material
Some of this material is today still found largely unaltered in meteorites.
Some of this material is today still found largely unaltered in meteorites.