I can see you with my eyes closed

Today I cam across extraocular photoreceptors which make up a fascinating story, explained by Wikipedia

A third class of mammalian photoreceptor cell was discovered during the 1990s: the photosensitive ganglion cells. These cells do not contribute to sight directly, but are thought to support circadian rhythms and pupillary reflex.

A paper (“seeing without eyes”) at theconversation.com has the details

“extraocular photoreceptors” are usually found in the central nervous system or in the skin, but also frequently in internal organs. … All the visual cells identified in animals detect light using a single family of proteins, called the opsins. These proteins grab a light-sensitive molecule – derived from vitamin A – that changes its structure when exposed to light. The opsin in turn changes its own shape and turns on signaling pathways in photoreceptor cells … The skin is where we see most other light receptors, particularly in active color-changing cells or skin organs called chromatophores.

I tried but could not find any link between chromatophores, vitamin D production and skin tanning in humans although such a link would make a lot of sense. While changing the search strategy to opsin expression in the skin, I found something interesting

Here we show that four opsins—OPN1‐SW, OPN2, OPN3 and OPN5—are expressed in the two major human epidermal cell types, melanocytes and keratinocytes, and the mRNA expression profile of these opsins does not change in response to physiological UVR doses. … Notably, OPN2 and OPN3 mRNA were significantly more abundant than other opsins and encoded full‐length proteins. Our results demonstrate that opsins are expressed in epidermal skin cells and suggest that they might initiate light–induced signaling pathways, possibly contributing to UVR phototransduction.

It seems that the effect is mainly  by OPN5

Human OPN5 also had an absorption maximum at 380 nm with spectral properties similar to mouse OPN5, revealing that OPN5 is the first and hitherto unknown human opsin with peak sensitivity in the UV region. OPN5 was capable of activating heterotrimeric G protein Gi in a UV-dependent manner.

which came into life by just a single mutation. As far as I understand it, UVR exposure is not leading to any opsin expression. Maybe it is just a very low threshold trigger for TYR et al ?

We investigated the effects of UV on human skin of various races before and at different times after a single 1 minimal erythemal dose UV exposure. … The expression of melanocyte-specific proteins (including TYR (tyrosinase), TYRP1 (tyrosinase-related protein 1), DCT (tyrosinase-related protein 2), MART1 (melanoma antigens recognized by T-cells) gp100 (Pmel17/silver), and MITF (micropthalmia transcription factor)) increased from 0 to 7 d after UV exposure, but the melanin content of the skin increased only slightly. The most significant change, however, was a change in the distribution of melanin from the lower layer upwards to the middle layer of the skin

A recent review in Current Biology pointed out that vitamin A-based chromophores were initially used in harvesting light energy, but have then become the most widely used light sensor.

Unfortunately many research questions have not been answered yet. We can only speculate about the function of extraocular photoreceptors in humans. In the mammalian retina it is probably part of a self-defense mechanism of the eye to avoid UVR induced destruction. There could be similar functions in the human skin including circadian entrainment, DNA protection and repair. Vitamin D production in the skin after UVR exposure is an independent process as ergosterol itself can efficiently absorb UVB radiation.

Finally here is a speculation about the pathophysiology: Extraocular photoreceptors could be key structures in photophobia, phototoxic and photo allergic reactions.