Our understanding of metabolic interactions between small symbiotic animals and bacteria or parasitic eukaryotes that reside within their bodies is extremely limited. This gap in knowledge originates from a methodological challenge, namely to connect histological changes in host tissues induced by beneficial and parasitic (micro)organisms to the underlying metabolites. We addressed this challenge and developed chemo-histo-tomography (CHEMHIST), a culture-independent approach to connect anatomic structure and metabolic function in millimeter-sized symbiotic animals. CHEMHIST combines chemical imaging of metabolites based on mass spectrometry imaging (MSI) and microanatomy-based micro-computed X-ray tomography (micro-CT) on the same animal. Both high-resolution MSI and micro-CT allowed us to correlate the distribution of metabolites to the same animal's three-dimensional (3D) histology down to submicrometer resolutions. Our protocol is compatible with tissue-specific DNA sequencing and fluorescence in situ hybridization for the taxonomic identification and localization of the associated micro(organisms). Building CHEMHIST upon in situ imaging, we sampled an earthworm from its natural habitat and created an interactive 3D model of its physical and chemical interactions with bacteria and parasitic nematodes in its tissues. Combining MSI and micro-CT, we present a methodological groundwork for connecting metabolic and anatomic phenotypes of small symbiotic animals that often represent keystone species for ecosystem functioning.