Sunlight. We can synthesize vitamin D ourselves when exposed to sunlight.
One of the explanations I've seen for why Europeans are white is to enhance this effect, because Europe gets comparatively less sunlight than other regions in which civilization initially spread, but was warm enough due to the gulf stream to support agriculture, which produces a diet lower in vitamin D. So between the comparatively lower sunlight and agriculture, Europeans needed to evolve to be able to generate more vitamin D from sunlight, which losing pigmentation helps with.