By analyzing 2.93 fb−1 of e+e− collision data taken at the center-of-mass energy of 3.773 GeV with the BESIII detector, the branching fractions of the inclusive decays D+→KS0X and D0→KS0X are measured to be (32.78±0.13±0.27)% and (20.54±0.12±0.18)%, respectively, where the first uncertainties are statistical and the second are systematic. These results are consistent with the world averages of previous measurements, but with improved precision.