Hair pigmentation, similar to skin pigmentation, is an aspect determined mainly by the amount and distribution of melanin. The proportion and amount of melanin is specific to each individual, resulting in a wide variety of hair colorations.
Hair color
The hair is the continuation of the scalp, formed mainly by keratin. Melanin is the chemical substance that, together with keratin, gives hair its color. There are two types of melanin, eumelanin and pheomelanin, and their quantity and proportion is what determines the final natural color. Specifically, people with darker shades have a higher amount of eumelanin, while those with lighter or reddish shades have a higher proportion of pheomelanin. In this hair coloring process, a few cell types are involved: the melanocytes where the pigment is manufactured, the keratinocytes in the hair to which the pigment is transferred and the fibroblasts in the dermis that regulate the melanocytes.
There are many possible hair shades (black, brown, blond, red, gray or white), with dark colors being the most common. The greatest heterogeneity is found in Europe, where in the north blond hair is the most common color. It is also common for hair color to be associated with skin and eye color, although not always.
Hair color can also vary in different cases. Age is the most important factor that can cause a change in hair color. As we age, melanin production progressively decreases, so that the hair takes on a grayish hue. The age at which this begins is mainly determined by genetics. Other conditions that can affect hair color are albinism, a genetic anomaly in which the ability to produce melanin is lost, vitiligo, which can cause loss of pigment in skin and hair, and other conditions such as malnutrition.

Number of observed variants
13.5 million variants
Number of loci analyzed
121 loci
Genes analyzed
Bibliography
Morgan MD, Pairo-Castineira E, Rawlik K, et al. Genome-wide study of hair colour in UK Biobank explains most of the SNP heritability. Nature Communications. 2018 Dec;9(1):5271.
National Library of Medicine (NIH). Is hair color determined by genetics? [Jun 2020]