Van der Waals encapsulation of two-dimensional materials in hexagonal boron nitride (hBN) stacks is a promising way to create ultrahigh-performance electronic devices(1-4). However, contemporary approaches for achieving van der Waals encapsulation, which involve artificial layer stacking using mechanical transfer techniques, are difficult to control, prone to contamination and unscalable. Here we report the transfer-free direct growth of high-quality graphene nanoribbons (GNRs) in hBN stacks. The as-grown embedded GNRs exhibit highly desirable features being ultralong (up to 0.25 mm), ultranarrow (<5 nm) and homochiral with zigzag edges. Our atomistic simulations show that the mechanism underlying the embedded growth involves ultralow GNR friction when sliding between AA '-stacked hBN layers. Using the grown structures, we demonstrate the transfer-free fabrication of embedded GNR field-effect devices that exhibit excellent performance at room temperature with mobilities of up to 4,600 cm(2) V-1 s(-1) and on-off ratios of up to 10(6). This paves the way for the bottom-up fabrication of high-performance electronic devices based on embedded layered materials.