In this study, we establish an explicit representation of solutions to \(\psi \) -Hilfer type linear fractional differential equations with variable coefficients in weighted spaces. Furthermore, we prove the existence and uniqueness of solutions for these equations. As a special case, we derive corresponding results for \(\psi \) -fractional differential equations with variable coefficients. To demonstrate the practical applications of our theoretical results, we derive explicit solutions for several representative cases, including the voltmeter equation in electrochemistry, the equation around an \(\alpha \) -ordinary point, and the fractional Ayre equation. Furthermore, we provide numerical simulations.