Rare earth(III) β-diketonates are highly remarkable luminophores in the visible spectral region among the rare earth compounds, owing to the efficient contribution from the 4f-4f intraconfigurational transitions. To get detailed structural insight into the RE3+ sites (RE = Eu, Gd, and Sm), X-ray absorption near-edge spectroscopy (XANES) can be very potent in probing the local chemical environment around the RE3+ ion. In this work, a PyFitIt machine learning approach was employed as a new strategy to simulate the Eu, Gd, and Sm L3-edge XANES and thereby determine the local atomic structure of the luminescence RE3+ β-diketonate complexes, [Eu(tta)3(H2O)2], [C4mim][Eu(dbm)4], [Gd(tta)3(H2O)2], and [Sm(dbm)3(phen)] (tta, 3-thenoyltrifluoroacetonate; dbm, dibenzoylmethane; phen, phenanthroline; and C4mim, 1-butyl-3-methylimidazolium bromide). Continuous Cauchy wavelet transform validated the PyFitIt calculated XANES by visualizing very efficiently the coordination geometries, composed of O and O/N backscatterers around the RE3+ (RE = Eu and Gd) and Sm3+ ions, respectively, as a pinkish-red color map in the two-dimensional images of the corresponding complexes. Extended X-ray absorption fine structure fit in Artemis also corroborated the three-dimensional structures generated by PyFitIt XANES simulation for all the compounds. Though, relatively slightly higher bond distance values for the Sm3+ complex are due to the higher atomic radius of the Sm3+ ion when compared to the Eu3+ and Gd3+ complexes. Meanwhile, higher Debye-Waller factor (σ2) values for the [C4mim][Eu(dbm)4] when compared to the [Eu(tta)3(H2O)2] indicated the structure disorder, owing to the distortion in the local geometry. It is noteworthy that the optical properties, described mainly by the Ωλ (λ = 2 and 4) 4f-4f intensity parameters, are very sensitive to the local coordination environment around the Eu3+ ion. Thus, a close agreement between the experimental and theoretically calculated Ωλ parameter values confirmed that the PyFitIt calculated square antiprismatic structures are precisely similar to the real structures of the Eu3+ complexes.