Background: Melatonin has been widely used as a "probiotic agent" capable of producing strong neurotransmitter secretion regulatory effects. The probiotics related researches also provide the evidence of microbial interactions with the gut-brain axis for mental health. In the present study, a zebrafish neural hyperactivity model was established using caffeine induction, and the regulation and mechanism of melatonin and probiotic on zebrafish neurotransmitter secretion disorder were explored. To further address the challenge that if the gut microbes play an essential role in the regulation of neurotransmitter secretion disorder via a process that involves melatonin, the Germ-free (GF) zebrafish model was used to verify the hypothesis. Results: Disorders of brain neurotransmitter secretion caused by caffeine, including that of dopamine (DA), γ-aminobutyric acid (γ-GABA), and 5-hydroxytryptamine (5-HT), were improved after interference treatment with melatonin or the probiotic. Metagenomic sequencing demonstrated that the melatonin-treated zebrafish gradually restored their normal intestinal microbial structure, while probiotic supplementation may restructure a new microbiome. Additionally, supplementation with melatonin significantly regulated intestinal microbial functional features, which indicated the gut microbiota plays the key role in the function of melatonin. Based on this activity, a Germ-free zebrafish model was applied to verified our hypothesis in the following validation experiment. Validation experiment results revealed that the effect on the zebrafish in the GF group could not achieve that on the zebrafish in the melatonin group after adding the same dose of melatonin, and subsequent real-time PCR and metabolic pathway analysis confirmed the conclusion. Meanwhile, the content of acetic acid and propionic acid in the gut of not-germ-free zebrafish decreased after caffeine induction and increased significantly after melatonin treatment. However, no acetic or propionic acids were found, detected, changed as there are germ-free zebrafish. Conclusions: In the present research, we identified the potential mechanism of melatonin regulation of neurotransmitter secretion disorder through the gut-brain axis, laying a foundation for exploring the prevention and treatment of some neuropsychiatric disorders by improving the intestinal microbiota.