The epidermal barrier is thought to protect sensory nerves from overexposure to environmental stimuli, and barrier impairment leads to pathological conditions associated with itch, such as atopic dermatitis (AD). However, it is not known how the epidermal barrier continuously protects nerves for the sensory homeostasis during turnover of the epidermis. Here we show that epidermal nerves are contained underneath keratinocyte tight junctions (TJs) in normal human and mouse skin, but not in human AD samples or mouse models of chronic itch caused by epidermal barrier impairment. By intravital imaging of the mouse skin, we found that epidermal nerve endings were frequently extended and retracted, and occasionally underwent local pruning. Importantly, the epidermal nerve pruning took place rapidly at intersections with newly forming TJs in the normal skin, whereas this process was disturbed during chronic itch development. Furthermore, aberrant Ca increases in epidermal nerves were induced in association with the disturbed pruning. Finally, TRPA1 inhibition suppressed aberrant Ca increases in epidermal nerves and itch. These results suggest that epidermal nerve endings are pruned through interactions with keratinocytes to stay below the TJ barrier, and that disruption of this mechanism may lead to aberrant activation of epidermal nerves and pathological itch.