Vitamin D is a group of fat-soluble secosteroids. In humans, vitamin D is unique both because it functions as a prohormone and because the body can synthesize it (as vitamin D3) when sun exposure is adequate (hence its nickname, the "sunshine vitamin").
Although "vitamin D" is commonly called a vitamin, some say it should not be classified as a vitamin because it can be synthesized by the human body. Vitamin D fits within the definition of vitamin as it is "an organic compound required as a vital nutrient in tiny amounts by an organism. In other words, an organic chemical compound (or related set of compounds) is called a vitamin when it cannot be synthesized in sufficient quantities by an organism, and must be obtained from the diet". As with other compounds called vitamins, it was discovered in an effort to find the dietary substance that was lacking in a disease, namely, rickets, the childhood form of osteomalacia.. Additionally, like other compounds called vitamins, in the developed world vitamin D is added to staple foods, such as milk, to avoid disease due to deficiency.
Measures of serum levels (from a vitamin D3 blood test) reflect endogenous synthesis from exposure to sunlight as well as intake from the diet, and it is believed that synthesis may contribute generally to the maintenance of adequate serum concentrations. The evidence indicates that the synthesis of vitamin D from sun exposure works in a feedback loop that prevents toxicity but, because of uncertainty about the cancer risk from sunlight, no recommendations are issued by the Institute of Medicine, USA, for the amount of sun exposure required to meet vitamin D requirements. Accordingly, the Dietary Reference Intakes for vitamin D assume that no synthesis occurs and that all of a person's vitamin D is from their diet, although that will rarely occur in practice.
Vitamin D is converted to calcidiol in the liver. Part of the calcidiol is converted by the kidneys to calcitriol, the biologically-active form of vitamin D. This circulates as a hormone in the blood, regulating the concentration of calcium and phosphate in the bloodstream and promoting the healthy growth and remodeling of bone. Calcidiol is also converted to calcitriol outside of the kidneys for other purposes, such as the proliferation, differentiation and apoptosis of cells; calcitriol also affects neuromuscular function and inflammation. 
Beyond its use to prevent osteomalacia or rickets, the evidence for other health effects of vitamin D supplementation in the general population is inconsistent. The best evidence of benefit is for bone health and a decrease in mortality in elderly women.
Source : http://upchar.blogspot.in/search/label/%E0%A4%96%E0%A4%A8%E0%A4%BF%E0%A4%9C-%E0%A4%B2%E0%A4%B5%E0%A4%A3-%E0%A4%B5%E0%A4%BF%E0%A4%9F%E0%A4%BE%E0%A4%AE%E0%A4%BF%E0%A4%A8