This question already has an answer here:

I'm pretty sure metal loses more of its structure as it heats up and magnetic properties in a material are caused by a particular combination of atomic arrangement and orbital levels so...how does the difference in rotation of Earth's liquid inner and outer core generate any kind of magnetic field? Why wouldn't Earth's magnetic field be even stronger if those two layers were completely stationary and solid?


marked as duplicate by John Rennie, Qmechanic Dec 17 '18 at 6:02

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.