How do scientists know the inside of the earth is made of layers?
The analysis by seismologists, over centuries, of velocities and times of travel of earthquake waves from epicenters, had been revealing layers inside the Earth and also the modes of transitions..
The compilation and analysis of data on the velocities and times of travel of the propagation of earthquake waves, from the respective epicenters, give clues to the layer-by-layer structure, in the interior of the Earth.
Despite that earthquake is a local event beneath land/sea, in the earthquake belts, the overall mapping, gives clues to shell-like layers of different structures, with varying densities..
With the advances in technology to make round-the-year seismographs, meticulous details on propagation of even too weak secondary waves near the surface and too-strong primary waves that reach great depths are recorded.
The updating and further classifications, for the better understanding of the Earth's interior, would continue, for ever.