Step 1: Protonation of methoxymethane :
Step 2: Nucleophilic attack of I – :
Step 3: The methanol produced in the previous step is used to combine with another HI molecule, resulting in the formation of methyl iodide. This is done at a high temperature with a lot of HI.