Mechanical stress in brain tissue is an important feature of the brain, likely to play key roles in brain development and brain injury. Here, we characterize residual stresses in grey matter and white matter from the deformed shape of tissue cylinders extracted from the brain using a biopsy needle and imaged with high-resolution magnetic resonance imaging (MRI). We use finite element simulations to reconstruct the stress state of tissue sections in the intact brain from images of corresponding sections of the deformed excised tissue. In both adult mouse and Yucatan minipig brains, cortical grey matter exhibited predominantly compressive stresses, while white matter exhibited strongly anisotropic tensile stresses. The direction of maximum tension in white matter generally aligns with axon orientation as observed with diffusion MRI in the minipig. These stress patterns (compressive in cortical grey matter, tensile along axons) are consistent with constrained cortical expansion and tension-induced axonal growth during brain development. These findings offer new insights into the biomechanical factors underlying brain morphogenesis, with implications for understanding neurodevelopmental disorders, brain injuries, and neurosurgical interventions.