The reason for this is that they're backstopped by fossil fuels. You install solar, it generates power when the sun shines and you burn coal or natural gas when it's cloudy or nighttime. The energy they produce is thereby cheaper, but can only satisfy so much of the total demand before requiring energy storage, which dramatically increases the cost. Satisfying the remaining demand with nuclear is better than satisfying it with fossil fuels.