Thermal interface materials play a pivotal role in efficiently transferring heat from heating devices to thermal management components, thereby reducing the risk of component degradation due to overheating. In this study, we propose a strategy for enhancing the out-of-plane thermal conductivity (TC) of composite materials by fabricating a three-dimensional (3D) thermal network within a polydimethylsiloxane (PDMS) matrix. Specifically, the composite material was designed to incorporate a dense thermal network comprising hexagonal boron nitride nanosheets (BNNSs) and nanodiamonds (NDs). The fabrication process commenced with the preparation of BNNSs through liquid-phase exfoliation, followed by the creation of a 3D BNNSs-NDs/polyimide aerogel thermal framework using a unidirectional solidification ice templating method and subsequent heat treatment. Vacuum impregnation and curing were then employed to finalize the production of the 3D BNNSs-NDs/PDMS composite material. Characterization analyses indicated that the addition of NDs filled the voids between BNNSs, leading to the densification of the thermal framework pore walls and the establishment of additional thermal pathways. Impressively, with concentrations of BNNSs and NDs of 17.99 and 7.71 wt %, respectively, the out-of-plane TC of the 3D BNNSs-NDs/PDMS composite material reached 1.623 W m-1 K-1, marking notable enhancements of 754.21% and 256.70% compared to those of pure PDMS and composites prepared via direct blending with randomly distributed BNNSs and NDs, respectively. Furthermore, the 3D BNNSs-NDs thermal framework improved the compressive strength and the dimensional stability of the composite material. Finite element simulations additionally confirmed the synergistic improvement of the TC achieved through the combination of BNNSs and NDs, demonstrating that the 3D BNNSs-NDs/PDMS composite material displayed superior heat conduction and a greater density of thermal pathways compared to those of its counterparts, including 3D BNNSs/PDMS and 3D NDs/PDMS composite materials. In summary, this work presents a strategy for enhancing the out-of-plane TC of polymer-based composite materials by incorporating vertically aligned thermal networks.