Liquid hydrocarbon fuels play an essential part in the global energy chain, owing to their high energy density and easy transportability. Olefins play a similar role in the production of consumer goods. In a post-oil society, fuel and olefin production will rely on alternative carbon sources, such as biomass, coal, natural gas, and CO2. The methanol-to-hydrocarbons (MTH) process is a key step in such routes, and can be tuned into production of gasoline-rich (methanol to gasoline; MTG) or olefin-rich (methanol to olefins; MTO) product mixtures by proper choice of catalyst and reaction conditions. This Review presents several commercial MTH projects that have recently been realized, and also fundamental research into the synthesis of microporous materials for the targeted variation of selectivity and lifetime of the catalysts.