This part of the web site contains information on how we can deduce the composition of the earth's interior. Samples of upper mantle can be found carried up in volcanoes (xenoliths) but these only provide indications down a few hundred km. but we can still make deductions, in part on the basis of the earth's physical structure. Surprisingly we can use data on the composition of the solar system, including samples of moon rock and meteorites.