Cells adapt their metabolism to physiological stimuli, and metabolic heterogeneity exists between cell types, within tissues, and subcellular compartments. The liver plays an essential role in maintaining whole-body metabolic homeostasis and is structurally defined by metabolic zones. These zones are well-understood on the transcriptomic level, but have not been comprehensively characterized on the metabolomic level. Mass spectrometry imaging (MSI) can be used to map hundreds of metabolites directly from a tissue section, offering an important advance to investigate metabolic heterogeneity in tissues compared to extraction-based metabolomics methods that analyze tissue metabolite profiles in bulk. We established a workflow for the preparation of tissue specimens for matrix-assisted laser desorption/ionization (MALDI) MSI that can be implemented to achieve broad coverage of central carbon, nucleotide, and lipid metabolism pathways. Herein, we used this approach to visualize the effect of nutrient stress and excess on liver metabolism. Our data revealed a highly organized metabolic tissue compartmentalization in livers, which becomes disrupted under high fat diet. Fasting caused changes in the abundance of several metabolites, including increased levels of fatty acids and TCA intermediates while fatty livers had higher levels of purine and pentose phosphate-related metabolites, which generate reducing equivalents to counteract oxidative stress. This spatially conserved approach allowed the visualization of liver metabolic compartmentalization at 30 μm pixel resolution and can be applied more broadly to yield new insights into metabolic heterogeneity in vivo.