Usually, the thermal conductivity is predominantly contributed by electrons in metals. In this work, by using first-principles calculations we find that in tungsten carbide (WC) the phonon-contributed thermal conductivities (κph) are 131 and 158 Wm−1K−1 along the a and c axes, respectively, three times as much as the electronic contribution (κe). In isotopically pure samples, κph can be further increased to 204 and 249 Wm−1K−1 along the a and c axes, respectively, which is comparable to the κe of Al. The anomalously large κph is attributed to the weak phonon-phonon and electron-phonon scattering, both of which have their origin in the electronic structure of the group-VI carbides. The Fermi energy falls within the pseudogap between the bonding and antibonding states, suggesting stronger interatomic bonding and weaker electron-phonon scattering than in group-IV and V carbides. The unique combination of strong interatomic bonding and large atomic mass of W results in a large acoustic-optical gap in the phonon dispersion, suppressing phonon-phonon scattering. In contrast, in another group-VI carbide, MoC, also with strong interatomic bonding, the smaller atomic mass of Mo increases the acoustic phonon frequencies and reduces the acoustic-optical gap. Furthermore, electron-phonon scattering, though not very strong in absolute magnitude, also plays an important role in phonon scattering, leading to a weak temperature dependence of κph in WC. The large thermal conductivity, persisting at high temperatures, facilitates the use of this material in applications such as cutting tools.