The Piranshahr ophiolite is located in northwest Iran. The Mawat ophiolite in northeast Iraq is the western continuation of the Piranshahr ophiolite. The whole rock geochemistry of mafic rocks from the Piranshahr ophiolite (in the Gerdikavalan regions) is studied and compared with mafic rocks from the Mawat ophiolite in northeast Iraq (in the Hasanbag, Walash and Naopurdan regions). Two groups can be identified among the ophiolitic basalts in northwest Iran and northeast Iraq. The first one is represented by Late Cretaceous calc‐alkaline basalts, displaying typical active continental margin signatures and thought to have been derived from the melting of enriched mantle sources modified by continental crust and subduction fluids. The second group is characterized by Eocene–Oligocene tholeiitic basalts, displaying signatures intermediate between mid‐ocean ridge basalt (MORB) and oceanic island basalt (OIB) and back‐arc basin (BAB) like magmas and suggested to have been derived from the melting of mixed asthenospheric‐lithospheric mantle sources in a slab window. We propose that the subduction signature is acquired by interaction of the mantle advected through the slab window in the upper part of the subducting plate.