Establishing efficient synthetic pathways for microbial production of biochemicals is often hampered by competing pathways and/or insufficient precursor supply. Compartmentalization in cellular organelles can isolate synthetic pathways from competing pathways, and provide a compact and suitable environment for biosynthesis. Peroxisomes are cellular organelles where fatty acids are degraded, a process that is inhibited under typical fermentation conditions making them an interesting workhouse for production of fatty-acid-derived molecules. Here, we show that targeting synthetic pathways to peroxisomes can increase the production of fatty-acid-derived fatty alcohols, alkanes and olefins up to 700%. In addition, we demonstrate that biosynthesis of these chemicals in the peroxisomes results in significantly decreased accumulation of byproducts formed by competing enzymes. We further demonstrate that production can be enhanced up to 3-fold by increasing the peroxisome population. The strategies described here could be used for production of other chemicals, especially acyl-CoA-derived molecules.