Tomography is a standard and invaluable technique that covers a large range of length scales. It gives access to the inner morphology of specimens and to the three-dimensional (3D) distribution of physical quantities such as elemental composition, crystalline phases, oxidation state, or strain. These data are necessary to determine the effective properties of investigated heterogeneous media. However, each tomographic technique relies on severe sampling conditions and physical principles that require the sample to be adequately shaped. For that purpose, a wide range of sample preparation techniques is used, including mechanical machining, polishing, sawing, ion milling, or chemical techniques. Here, we focus on the basics of tomography that justify such advanced sample preparation, before reviewing and illustrating the main techniques. Performances and limits are highlighted, and we identify the best preparation technique for a particular tomographic scale and application. The targeted tomography techniques include hard X-ray micro- and nanotomography, electron nanotomography, and atom probe tomography. The article mainly focuses on hard condensed matter, including porous materials, alloys, and microelectronics applications, but also includes, to a lesser extent, biological considerations.