>>76516713 (OP)
Use one of the many online sun position calculators
If the sun is lower than 45 degrees in the sky, you don't get any UVB dose
You'll still make nitrous oxide which lowers your bp and you'll still positively influence your circadian rhythm, but no vitamin D production will occur
In higher lattitudes the sun doesn't get high enough in fall/winter/spring even at solar noon to create D and this is useful to know so you can supplement or use an artificial tanning bed
If the sun is high enough to make D then lay out with mininal clothing just enough to barely get the lightest flush of temporary erythema then roll over & repeat
Do this every other day or so
If you're lily white this might be literally 2 minutes per side
If you're a med or a shitskin, put your skin tone and the sun angle into a vitamin d calculator and use that recommended exposure time since it's difficult to judge when your skin is getting burned
Do this 3 or 4 times per week