Clouds do not significantly block UV.
This is a dangerous myth, and many people who have gone without sunscreen on a cloudy day regret having believed it. Clouds are better at blocking visible light than UV rays, and unless there is complete cloud cover (no shadows), some harmful UV radiation is still getting through. In fact, there is some evidence to suggest that UV rays may actually be more dangerous on partly cloudy days. This may seem absurd or counter-intuitive, but there are some good reasons having to do with the nature of UV and of clouds.
When you go outside during the day, you are actually exposed to two kinds of Ultraviolet light-UVA, linked to long-term skin damage, and the deadly UVB, which directly damage DNA and are thought to cause most skin cancers. The third kind, UVC, does not make it through our atmosphere. The amount of UV you are exposed to depends on many factors, including the time of year, time of day, elevation, and cloud cover; the EPA maintains a UV index with forecasts for your area. Under heavy cloud cover, you may be protected from some UV, but partly cloudy conditions are suspected to aggravate UV rays through reflection and diffusion. 
Cloud Enhancement and Ultraviolet Rays
Most clouds block some degree of UV rays. The thicker and denser the clouds, the more UV rays are filtered.  But clouds can also enhance the intensity of the ultraviolet rays that reach ground level. How is this possible? Because clouds are made up of tiny water droplets formed around dust, they are highly reflective; that is why they appear white. Dense cumulus clouds reflect the UV radiation and allow it to bounce off their sides and get through cloud cover, while wispier clouds redirect the rays in all directions. High clouds refracting UV rays and lower clouds reflecting them may significantly increase the UV levels on the ground. The effect can be amplified by haze, fog, and especially snow. 
Recent studies have demonstrated that cloud enhancement of UV rays can be as high as 25%.  This is exacerbated by some people's failure to apply sunblock on cloudy days. Even on a completely overcast day, some UV radiation gets through, and on partly cloudy days, your risk for skin cancer and melanoma may actually increase.