In mice, it is possible to induce a psoriasis-like condition by applying imiquimod; here, the production of interleukin-23 that is stimulated by such skin inflammation is shown to depend on the interaction of nociceptors expressing the Nav1.8 and TRPV1 channels with skin-resident dendritic cells. Repeated topical application of the antiviral immune modifier imiquimod (IMQ) to murine skin provokes interleukin-23-mediated inflammatory lesions that resemble human psoriasis. Ulrich von Andrian and colleagues show that the production of skin inflammation in this disease model depends on the interaction of a subset of sensory neurons expressing the ion channels TRPV1 and Nav1.8 with skin-resident dendritic cells. Taken together with other recent work, this finding suggests a scenario in which noxious pain fibres integrate environmental signals to modulate local immune responses to a variety of infectious and pro-inflammatory stimuli. The skin has a dual function as a barrier and a sensory interface between the body and the environment. To protect against invading pathogens, the skin harbours specialized immune cells, including dermal dendritic cells (DDCs) and interleukin (IL)-17-producing γδ T (γδT17) cells, the aberrant activation of which by IL-23 can provoke psoriasis-like inflammation1,2,3,4. The skin is also innervated by a meshwork of peripheral nerves consisting of relatively sparse autonomic and abundant sensory fibres. Interactions between the autonomic nervous system and immune cells in lymphoid organs are known to contribute to systemic immunity, but how peripheral nerves regulate cutaneous immune responses remains unclear5,6. We exposed the skin of mice to imiquimod, which induces IL-23-dependent psoriasis-like inflammation7,8. Here we show that a subset of sensory neurons expressing the ion channels TRPV1 and Nav1.8 is essential to drive this inflammatory response. Imaging of intact skin revealed that a large fraction of DDCs, the principal source of IL-23, is in close contact with these nociceptors. Upon selective pharmacological or genetic ablation of nociceptors9,10,11, DDCs failed to produce IL-23 in imiquimod-exposed skin. Consequently, the local production of IL-23-dependent inflammatory cytokines by dermal γδT17 cells and the subsequent recruitment of inflammatory cells to the skin were markedly reduced. Intradermal injection of IL-23 bypassed the requirement for nociceptor communication with DDCs and restored the inflammatory response12. These findings indicate that TRPV1+Nav1.8+ nociceptors, by interacting with DDCs, regulate the IL-23/IL-17 pathway and control cutaneous immune responses.