There are two primary reactions to generate ethers: either by Dehydration of Alcohols or by the Williamson Synthesis. Acyclic ethers can be prepared using Williamson's synthesis, which involves reacting an alkoxide with a haloalkane. As stated previously, alkoxides are created by reacting an alcohol with metallic sodium or potassium, or a metal hydride, such as sodium hydride (NaH). To minimize steric hindrance and achieve a good yield, the haloalkane must be a primary haloalkane. This is because the mechanism is SN2, where the oxygen atom does a backside attack on the carbon atom with the halogen atom, causing the halogen atom to leave with its electrons.