Nanocomposite materials consisting of metal oxide and carbon are of interest as electrode materials for both high rate intercalation-type and high capacity conversion-type charge storage processes. Facile synthesis processes like the pyrolysis of an organic carbon-source can yield a well-dispersed carbon phase within the metal oxide structure. Detailed understanding of the carbon formation process is required to tailor the resulting material microstructure. Herein, both the formation and the final microstructure of a molybdenum oxide/carbon nanocomposite are studied in detail. Octylamine assembled in the interlayer space of layered MoO3 serves as a carbon source. The structural changes during pyrolysis are characterized using a combination of in situ heating X-ray diffraction with simultaneous FTIR- and mass spectroscopy-coupled thermogravimetric analysis experiments. These reveal mobility and partial desorption of octylamine and interlayer water at low temperatures, octylamine decomposition and loss of long-range order at intermediate temperatures, and carbothermic reduction of molybdenum oxide at high temperatures during pyrolysis. The resulting nanocomposite mainly contains nanocrystalline MoO2 domains surrounded by a well-dispersed carbon phase, as observed with scanning transmission electron microscopy of focus-ion beam prepared cross-sectional lamellae. The electrochemical behavior is evaluated in organic, lithium-containing electrolyte for both intercalation and conversion-type reactions, showing good intercalation kinetics and a high first cycle efficiency for the conversion-type reaction.