We present geological, whole-rock geochemical and Sr–Nd isotopic, and zircon U–Pb geochronological data for mafic rocks found as angular fragments in the Jinghe ophiolitic mélange of the Northern Tianshan orogenic belt, northwest China. The investigated exotic blocks comprise layered and massive gabbros and pillow basalts that are embedded in a serpentinite-rich matrix. The 380.5 ± 4.9 Ma layered gabbros have chondrite-normalized rare earth element (REE) patterns characterized by significant depletions in the light rare earth elements (LREE) and positive Eu anomalies, suggesting that the petrogenesis of these rocks was controlled by cumulus processes. The 381.5 ± 3.7 Ma massive gabbros have near-flat normal-type mid-ocean ridge basalt (MORB)-normalized multi-element patterns with moderate to strong negative Nb–Ti anomalies. These rocks have initial 87Sr/86Sr ratios (87Sr/86Sr(i)) of 0.703825–0.704758 and high εNd(t) values (+6.7 to +9.0). Two compositional groups of basalts can be recognized: ocean island basalt (OIB)- and enriched MORB-type rocks. Both groups display variable enrichments in large-ion lithophile elements (LILE) in N-MORB-normalized trace element diagrams. Semi-quantitative modelling demonstrates that the parental magmas of the massive gabbros were derived by 5%–10% partial melting of a spinel-bearing lherzolite source influenced by minor inputs of subducted crustal components. The parental magmas of the subalkaline and alkaline basalts were derived by 10%–20% and 1%–5% polybaric melting, respectively, of a lherzolite source containing spinel and garnet in equal amounts. The petrogenesis of the Jinghe basalts can be linked to continental rifting followed by seafloor spreading caused by upwelling of a mantle plume. The petrogenesis of the gabbros is linked to plate re-organization that provided the geodynamic impetus for southwestward subduction in the North Tianshan Ocean, and the onset of incorporation of oceanic materials with different origins into a growing accretionary prism during the Late Devonian. Accretion resulted in chaotic mixing of dismembered pieces of variably deformed oceanic rocks, which are now preserved as an extensive block-in-matrix ophiolitic mélange.