Dillenia indica (Linn.) has been reported by several biological activities, including anti‐inflammatory, antioxidant, antidiabetic, anti‐hyperglycemic, antiproliferative, antimutagenic, anticholinesterase, and antimicrobial. In Brazilian traditional medicine, the fruits of D. indica have been used to treat general topical pain and inflammation, but with no scientific validation. Thus, aiming to study its chemical constitution and antinociceptive properties, the crude extract (CE) and fractions obtained from the fruits of D. indica were submitted to an in vivo pharmacological evaluation and a dereplication study by LC‐MS/MS analysis, assisted by the Global Natural Product Social Molecular Networking (GNPS). The oral antinociceptive activity of the fruits of D. indica and the possible participation of the opioid and cannabinoid systems were demonstrated in the formalin‐induced nociception model. The chemical dereplication study led us to identify several known chemical constituents, including flavonoids, such as caffeoylmalic acid, naringenin, quercetin, and kaempferol. According to literature data, our results are compatible with significant antinociceptive and anti‐inflammatory activities. Therefore, the flavonoid constituents of the fruits of D. indica are probably responsible for its antioxidant, anti‐inflammatory, and antinociceptive effects mediated by both opioid and cannabinoid systems, confirming its folk use in the treatment and relief of pain.