RFamide neuropeptide VF (NPVF) is expressed by neurons in the hypothalamus and has been implicated in nociception, but the circuit mechanisms remain unexplored. Here, we studied the structural and functional connections from NPVF neurons to downstream targets in the context of nociception, using novel transgenic lines, optogenetics, and calcium imaging in behaving larval zebrafish. We found a specific projection from NPVF neurons to serotonergic neurons in the ventral raphe nucleus (vRN). We showed NPVF neurons and vRN are suppressed and excited by noxious stimuli, respectively. We combined optogenetics with calcium imaging and pharmacology to demonstrate that stimulation of NPVF cells suppresses neuronal activity in vRN. During noxious stimuli, serotonergic neurons activation was due to a suppression of an inhibitory NPVF-ventral raphe peptidergic projection. This study reveals a novel NPVF-vRN functional circuit modulated by noxious stimuli in vertebrates.