Background and AimsAnesthetics such as propofol, esketamine and nalbuphine are used during the upper gastrointestinal endoscopy to achieve and maintain the desired sedation level. The aim of the study was to evaluate the effectiveness and safety of propofol-nalbuphine and propofol-esketamine in children.MethodsA multi-centered study was performed at three tertiary class-A hospitals. Children between 3 and 12 years old undergoing diagnostic painless upper gastrointestinal endoscopy were included and randomly divided into esketamine or nalbuphine group to estimate the primary outcome of successful endoscope insertion. The patients were given esketamine 0.5 mg/kg and propofol 2 mg/kg intravenously in esketamine group, with nalbuphine 0.2 mg/kg and propofol 2 mg/kg in the nalbuphine group. The primary outcome was success rate for the first attempt of endoscope insertion in each group. Secondary outcomes included the safety of both anesthesia regimens and gastroenterologist's satisfaction. We used the Face, Leg, Activity, Cry and Consolability (FLACC) scale to evaluate the level of pain before and during the procedure and the Pediatric Anesthesia Emergence Delirium (PAED) scale to assess the level of agitation and delirium after awakening from anesthesia.ResultsAmong 246 patients, 200 were randomly included in the final intention-to-treat analysis, with 100 patients in each group. The success rate for the first attempt of endoscope insertion in the esketamine group was higher than the nalbuphine group (97% vs. 66%; P < 0.01). The heart rate and mean arterial pressure after intraoperative administration in the esketamine group were higher than those in the nalbuphine group, while the delirium incidence during awakening was higher in esketamine group (all P < 0.05).ConclusionThe success rate for the first attempt of endoscope insertion of children undergoing upper gastrointestinal endoscopy in the esketamine group was higher than the nalbuphine group, propofol-related hemodynamic changes were reduced accordingly, while the incidence of esketamine-related adverse effects could be high.Clinical Trial RegistrationChinese Clinical Trial Registry: ChiCTR2000040500.