The objectives of this study were to compare the quality of sedation provided by intravenous (i.v.) and intramuscular (im) ketamine for pediatric magnetic resonance imaging (MRI). This study was a non-randomized, single-blinded, and prospective observational study. After receiving approval from the Institutional Ethics Committee, a total of 108 children aged 2-7 years were divided into two groups, with 54 children in each group. In the i.v. group, children received ketamine at a dose of 1.5 mg/kg intravenously, while in the im group, children received ketamine at a dose of 4 mg/kg intramuscularly. If a Ramsay sedation score of 6 (RSS-6) was not achieved, half of the loading dose of ketamine was repeated. In both groups, rescue propofol boluses of 1 mg/kg intravenously were administered whenever the child moved. The primary outcome measure was the quality of sedation, which was assessed by a blinded radiologist. The time taken to reach RSS-6, the number of rescue propofol boluses, the total time wasted in taking repeat sequences, and the time required to achieve a modified Aldrete score of 9 (MAS-9) were recorded. The im group demonstrated significantly better sedation quality. In the i.v. group, the time to achieve RSS-6 was significantly shorter, but it required more rescue propofol boluses to maintain sedation. The i.v. group also experienced a notable increase in the total time wasted during repeat sequences. On the other hand, the i.v. group exhibited a shorter time to reach MAS-9 compared to the im group. The im group showed superior sedation quality when compared to the i.v. group. However, it is important to consider that the im group experienced a longer recovery time.