Solar plays a crucial role in supporting energy sector activities in Indonesia. The fluctuating price of solar is influenced by crude oil production, as crude oil is the main raw material in solar production. The Russia-Ukraine war, which reached its peak in March 2020, also impacted global oil production, given that Russia is one of the largest oil producers and exporters in the world. This study aims to model the effect of crude oil production on the Solar Wholesale Price Index (SWPI) in Indonesia after the Russia-Ukraine war using the Least Squares Spline estimator approach. This approach was chosen because the relationship between the variables is complex and nonlinear, making linear models unsuitable. The results show that the best model is a nonparametric model with three knot points at a polynomial degree of one, which explains 90.26% of the variability in crude oil production relative to the SWPI. The optimal knot points were selected using the Generalized Cross Validation (GCV) method, resulting in a minimum GCV value of 320.9889. Crude oil production was found to have a significant effect on the SWPI and meets the classical assumption tests. However, this study has limitations, as it only considers the effect of crude oil production without including other external factors, such as energy policies or geopolitical influences. Additionally, the model still has limitations in capturing more complex relationship patterns. This study offers an original contribution through the application of the Least Squares Spline estimator approach, which has not been widely used before in analyzing the relationship between crude oil production and SWPI in Indonesia. For future research, it is recommended that the model be expanded by considering more knot points and higher polynomial degrees to capture more complex relationship patterns between these variables.