Because of the unique anatomical and physiological structure with excellent barrier impediment of the human eye, ocular drug delivery faces some inevitable challenges such as low bioavailability of administered drugs locally or systemically. The in-situ gel-forming mucoadhesive hydrogels are one of the appealing systems for ocular drug delivery that can prolong the precorneal retention time and provide sustained release conditions as well as improve ocular bioavailability. Chitosan (CS), due to its unique properties (biocompatibility, biode-gradability, mucoadhesive property, and positive charge), can interact intimately with the cornea. Thus, CS has been used in the preparation of thermo-responsible mucoadhesive hydrogels. Here, water-soluble CS was ob-tained via grafting with modified polyethylene glycol (PEG-g-CS) with a degree of substitution of around 22.4%. Subsequently, its gel formation was accomplished using sodium beta-glycerophosphate and sodium bicarbonate and loaded with vancomycin and prednisolone. Fourier-transform infrared spectroscopy and nuclear magnetic resonance were used to ensure the formation of bonds between the functional groups and their interaction. Furthermore, scanning electron microscopy, thermogravimetric analysis, rheometric testing, and swelling techniques were used to identify the hydrogel surface structure, the thermal stability of the polymer, rheometric, and swelling properties. After vancomycin and prednisolone loading, their release was measured in vitro and ex vivo at pH 7.4. Microbial tests were performed on Staphylococcus aureus and cytotoxicity was performed on the human umbilical vein endothelial cells. Based on our findings, the water-soluble PEG-g-CS copolymer displayed a great deal of rapid gel formation under physiological conditions in the presence of a physical crosslinker. The prepared hydrogel showed a sustained-release profile for vancomycin and prednisolone with appropriate anti-bacterial activity in vitro.