Efficient and robust electrocatalysts for both the oxygen reduction reaction (ORR) and oxygen evolution reaction (OER) play key roles in energy conversion and storage devices. In this work, we construct a bifunctional catalyst by homogeneously dispersing Co9S8 nanoparticles on a nitrogen (N), sulfur (S), and phosphate (P) ternary-doped 3D graphene aerogel (NSPG) matrix via a facile pyrolysis method. Because of the N, S, and P ternary-doping effects, abundant defects and channels are produced in the edge of graphene, resulting in a high specific BET surface area (SBET) of 657 m2 g–1. With the incorporation of Co9S8 nanocrystals into NSPG, the produced catalyst (Co9S8/NSPG-900) possesses an SBET of 478 m2 g–1 with porous characteristics. The synergy of structure and composition features enables fast electrochemical kinetics of the catalyst, leading to efficient ORR activity with a half-wave potential of 0.800 V versus the reversible hydrogen electrode (RHE), a limiting current density of 7.26 mA cm–2, high ...