First, it depends on two things - how far from the equator you are, and the time of day. In any case, outside the hours of about 10am to 3pm the angle of the sun rays is such that the UVB that is required is filtered by the atmosphere. But the further north or south you are, the less UVB will get through to you except in high summer. Next, there's sub block. Anything above SPF 15 and you'll essentially make no vitamin D. Then there's the fact that manufacture of vitamin D declines with age, so the older you get the less you'd make naturally. Yet another factor is skin colour. The more tanned we are, or the darker our skin, the less UVB will get the the appropriate cholesterol mollecules to begin the vitamin D process.
In winter therefore we tend to make very little vitamin D, and prehaps the only sources in our diets are oily fish like salmon and mackerel, and chicken. Chicken?? Yes, because farmed chickens are given vitamin D to strengthen THEIR bones and to help them make less fragile eggs.
So yes, 20 minutes for a lightly tanned person in a country not too far from the equator at the right tome of the year and the right time of day.
The delicious irony of the desire to cover up and protect ourselves from the sun as much as we now do is that the rate of skin cancer has actually increased overall. Why? Because apparently this leaves us way deficient in vitamin D, which has some link to incidence of cancer. Also, the most serious skin cancers, the malignant melanomas, also tend to occur on skin that isn't exposed to the sun.