The title reaction proceeded well to yield silicon (oxy)nitride at 973-1323 K using a plug-flow reactor. The degree of nitridation was studied as a function of temperature and time of nitridation, the sample weight, and the flow rate of ammonia. It was dependent on the reaction temperature and the amount of ammonia supplied per sample weight. The nitridation at 1273 K for 10-25 h yielded the oxynitride with 36-39 wt% nitrogen, which was very close to 40 wt% of Si3N4. Characterization with X-ray diffraction, field-emission scanning electron microscopy and transmission electron microscopy measurements, and nitrogen adsorption revealed the conversion of MCM-41 to the corresponding oxynitride without essential loss of the mesoporous structure, the decrements of the lattice constant and the pore diameter by 20-35%, and the increments of the wall thickness by ca. 45%. Solid-state 29Si nuclear magnetic resonance spectra during the nitridation clearly showed fast decrease in SiO4 species and slow in SiO3(OH). Various intermediate species, SiOxNy(NH2 or NH)z, were observed to be formed and finally, ca. 70% SiN4 species, ca. 20% SiN3(NH2 or NH), and ca. 10% SiON2(NH2 or NH) were produced, being consistent with the results of the above mentioned elemental analysis.