Dimethyl sulfate

# Overview
Dimethyl sulfate is a chemical compound with formula (CH3O)2SO2.   As the dimethyl ester of sulfuric acid. Its formula is often written as (CH3)2SO4 or even Me2SO4; where Me is methyl, or CH3.  Me2SO4 is mainly used as a methylating agent in organic synthesis.
Under standard conditions, Me2SO4 is a colourless oily liquid with a slight onion-like odour. Like all strong alkylating agents, Me2SO4 is highly toxic. Its use as a laboratory reagent has been superseded to some extent by methyl triflate, CF3SO3CH3, the methyl ester of trifluoromethanesulfonic acid.

# History
Dimethyl sulfate was first discovered in the early 1800s in an impure form.  P. Claesson later extensively studied its preparation.

# Production
Dimethyl sulfate can be synthesized in the laboratory with many different syntheses:
Another possible synthesis involves distillation of methyl hydrogen sulfate:
Methyl nitrite and methyl chlorosulfonate also result in dimethyl sulfate:
In the United States Me2SO4 has been produced commercially since the 1920s.  A common process is the continuous reaction of dimethyl ether with sulfur trioxide.

# Uses
Dimethyl sulfate is best known as a reagent for the methylation of phenols, amines, and thiols.  Typically, one methyl group is transfer more quickly than the second methyl group.  Methyl transfer is typically assumed to occur via an SN2 reaction.  Although dimethyl sulfate is highly effective and affordable,  its toxicity has encouraged the use of other methylating reagents. Methyl iodide is a reagent used for O-methylation, like dimethyl sulfate, but is less hazardous and more expensive. Dimethyl carbonate has far lower toxicity compared to both dimethyl sulfate and methyl iodide and can be used to instead of dimethyl sulfate for N-methylation.  In general the toxicity of methylating agents is correlates with their efficiency as methyl transfer reagents.

## Methylation at oxygen
Most commonly, Me2SO4 is employed to methylate phenols.  Some simple alcohols are also suitably methylated, as illustrated by the conversion of tert-butyl alcohol to t-butyl methyl ether:
Alkoxide salts are rapidly methylated:

## Methylation at amine nitrogen
Me2SO4 is used to prepare both quaternary ammonium salts or tertiary amines:
Quaternized fatty ammonium compounds are used as  a surfactant or fabric softeners.  The methylation of a tertiary amine is illustrated as:

## Methylation at sulfur
Similar to the methylation of alcohols, mercaptide salts are easily methylated by Me2SO4:
An example is:
This method has been used to prepare thioesters:

## Other Uses
Dimethyl sulfate can be used with DNA for the base-specific cleavage of guanine by rupturing the imidazole rings present in guanine.  This process can be used to determine base sequencing, cleavage on the DNA chain, and other applications.

# Safety
Dimethyl sulfate is likely carcinogenic and mutagenic, poisonous, corrosive, environmentally hazardous and volatile (presenting an inhalation hazard). Some consider it a potential chemical weapon. Dimethyl sulfate is absorbed through the skin, mucous membranes, and gastrointestinal tract. Delayed toxicity allows potentially fatal exposures to occur prior to development of any warning symptoms. Protective clothing includes goggles, gloves tested for dimethyl sulfate and a gas mask to prepare against the inhalation hazard in the case of a spill. Concentrated solutions of bases (ammonia, alkalis) can be used to hydrolyze spills and residues on contaminated equipment. Plain water cannot be assumed to hydrolyze dimethyl sulfate quickly enough for decontamination purposes. The hydrolysis products, monomethyl sulfate and methanol, are environmentally hazardous.