The more melanin a person has in their skin the darker their complexion, therefore the fairer the skin the less melanin. So when a person sunbathes the production of melanin is responsible for tanning. As melanin is the chemical that determines color, the more there is in a person's skin, the darker that person's skin will be.
Melanin is made in cells known as melanocytes, which are found in the upper layer of the epidermis. Some ethnic groups melanocytes cells produce melanin more frequently, thereby creating more pigment within their skin. Also, melanocytes produce more melanin when stimulated by certain factors such as proper supplementation and sunlight. Melanin protects the body by absorbing ultraviolet radiation from sun, so higher levels of the skin pigment reduces the risk of common skin cancer.
MELANIN AND PHOTOPROTECTION
Photoprotection is a group of mechanisms that nature has developed to minimize the damage that the human body suffers when exposed to UV radiation. This damage mostly occurs in the skin, but the rest of the body can be affected by the oxidative stress caused by UV light.
Photoprotection of the human skin is achieved by extremely efficient internal conversion of DNA, proteins and melanin. Internal conversion is a photochemical process that converts the energy of the UV photon into small, harmless amounts of heat. If the energy of the UV photon were not transformed into heat, then it would lead to the generation of free radicals or other harmful reactive chemical species (e.g. singlet oxygen, or hydroxyl radical).
In DNA this photoprotective mechanism evolved four billion years ago at the dawn of life. The purpose of this extremely efficient photoprotective mechanism is to prevent direct DNA damage and indirect DNA damage. The ultrafast internal conversion of DNA reduces the excited state lifetime of DNA to only a few femtoseconds (10 −15s)-this way the excited DNA has not enough time to react with other molecules.
For melanin this mechanism has developed later in the course of evolution. Melanin is such an efficient photoprotective substance that it dissipates more than 99.9% of the absorbed UV radiation as heat. This means that less than 0.1% of the excited melanin molecules will undergo harmful chemical reactions or produce free radicals.