The source of heat that keeps the Earth's core hot and molten is the decay of radioactive elements, predominantly uranium, thorium and potassium.
The Mantle and Crust act as insulators for the Earth's Core.