The melting thermodynamic characteristics of 2- to 20-layered onion-like fullerenes (OLFn) (C60@C240 to C60@···@C6000···@C24000) are comprehensively explored using first-principles-based ReaxFF atomistic simulations and random forest machine learning (RF ML). It is revealed that OLFn shows lower thermal stability than the counterparts of single-walled fullerenes (SWFn). The melting point of SWFn increases monotonically with increasing size, whereas for OLFn, an unusual size-dependent melting point is observed; OLFn with intermediate size shows the highest melting point. For small OLFn, the melting occurs from the inner to the outer, whereas for large OLFn, it nucleates from the inner to the outer and to intermediate fullerenes. The melting and erosion behaviors of both SWFn and OLFn are mainly characterized by the nucleation of non-hexagons, nanovoids, carbon chains and emission of C2. RF ML model is developed to predict the melting points of both SWFn and OLFn. Moreover, the analysis of the feature importance reveals that the Stone-Wales transformation is a critical pathway in the melting of SWFn and OLFn. This study provides new insights and perspectives into the thermodynamics and pyrolysis chemistry of fullerenic carbons, and also may shed some lights onto the understanding of thermally-induced erosion of carbon-based resources and spacecraft materials.