In this study, an in situ gel-forming chitosan hydrogel was prepared with the use of glutamate salt of chitosan (Ch-Ga), β-glycerophosphate (Gp), and morphine (Mor). The paper is focused on in vitro physicochemical properties and in-vivo analgesic effects of the prepared chitosan hydrogel. The thermosensitive properties of prepared chitosan hydrogel were evaluated during the different temperatures and times. The physicochemical properties of chitosan hydrogel were investigated by infrared (IR) spectroscopy and X-ray diffraction analysis (XRD). Also, its cell cytotoxicity effects were evaluated in murine NIH/3T3 normal cells. Subsequently, the distribution of chitosan hydrogel in the nasal cavity of rats and its analgesic responses were evaluated. The prepared chitosan hydrogel showed that it could be gelled at the temperature of 34 °C before leaving the nose in the shortest possible time of 30 s. The analgesic responses of the intranasal (IN) injection of chitosan hydrogel (IN-chitosan hydrogel, 10 mg Mor/kg) in a single unit dose in rat relative to the placebo and intranasal or intraperitoneal (IP) injection of free morphine solution (IN-Free Mor or IP-Free Mor, 10 mg Mor/kg) via the hot plate test, reveal that the IN-chitosan hydrogel could induce fast analgesic effects of morphine with maximum possible effect (MPE) of 93% after 5 min compare to the IN-Free Mor and IP-Free Mor with MPE of 80% after 15 min and 66% after 30 min, respectively. Also, prolonged analgesic effects with MPE of 78 % after 6 h of injection were only seen in the IN-chitosan hydrogel injected group. The obtained fluorescent images of rat's brain injected with IN-chitosan hydrogel containing doxorubicine (Dox) as a fluorescent agent showed that the mucosal adhesive and absorption enhancer properties of IN-chitosan hydrogel resulting in longer presence of them in the nasal cavity of rats followed by more absorption of Dox from the blood vessels of olfactory bulbs with a 74% color intensity compared to the IN-Free Mor and IN-Free Dox with 15%. These data reveal that the IN-chitosan hydrogel could induce fast and prolonged analgesic effects of morphine compare to the IN/IP-Free Mor, which could be considered as an in situ gel-forming thermosensitive chitosan hydrogel for nasal delivery of wide ranges of therapeutic agents.