Uh.. they aren't used in solar-panels, ttbomk.
They're used in neodymium magnets.
They're used in TIG-welding electrodes ( ceriated, etc. )
Without rare-earths, we've got no rare-earth magnets ( & hence no powerful permanent-magnet motors ) AND no TIG-welding ( except for the pure-tungsten ones, & the radioactive thoriated ones ).
You can't stop needing specific elements, or categories-of-elements: chemistry doesn't work that way, sorry.
_ /\ _