# Methylation of nitroalkanes with diazomethane

It is known that diazomethane can methylate various compounds with acidic hydrogens. Diazomethane is most well-known for the efficient synthesis of methyl esters from carboxylic acids. Clayden, Greeves, & Warren (2012) mention that it can also methylate phenols ($$\ce {pK_a = 10}$$), but not straight-chain alcohols ($$\ce {pK_a = 16}$$). The latter not being acidic enough. I was just wondering if nitroalkanes ($$\ce {pK_a = 10}$$) would be able to be methylated by diazomethane?

Reference

Clayden, J., Greeves, N., & Warren, S. (2012). Organic Chemistry (2nd ed.). New York : Oxford University Press Inc.

• Never seen this reaction - which doesn't mean there are not examples though – Waylander Nov 28 '18 at 12:16
• That pKa value looks wrong to me, for simple nitroalkanes. I'm sure it is substantially higher for nitromethane, eg. ca. 17. – Organic Chemistry Explained Nov 28 '18 at 12:20
• @OrganicChemistryExplained I am referring to the pka in water. – Tan Yong Boon Nov 28 '18 at 12:21
• @OrganicChemistryExplained According to Clayden's, pka of nitromethane is indeed 10. – Tan Yong Boon Nov 28 '18 at 12:23
• OK, it looks like the ~10 value may be in water, although I haven't been able to find the original ref, whereas the pKa is 17.2 in DMSO - JACS 1975, 97(24), 7006. Like @Waylander, I haven't seen this reaction. I suspect that if it is acidic enough in the right solvent to treat with diazomethane, it give O-methylation rather than C-methylation, and that O-methyl product may readily hydrolyse on workup or attempts at purification. Interesting question! – Organic Chemistry Explained Nov 28 '18 at 12:45