Transition metal phosphides are promising oxygen evolution reaction (OER) catalysts due to their earth-abundant and cost-effective features. Here, nanostructured CoP nanoparticles locked in hollow nitrogen doped carbon frameworks (CoP@HNC) were successfully designed and characterized for their morphology, composition, and electrochemistry. In a typical low-temperature phosphorization process, the Co species in carbonized poly-dopamine (PDA) coated ZIF-67 are converted to either hollow CoP or small-sized solid CoP nanoparticles governed by the nanoscale Kirkendall effect. The PDA layers derived nitrogen-doped carbon components feature a hollow polyhedral structure, with CoP nanoparticles imbedded in the shell. CoP@HNC demonstrates a low overpotential of 327 mV for 10 mA cm-2 and a good operational stability (72 h) for alkaline OER. The HNC encapsulation affords the low electronic resistance between CoP nanoparticles, as well as the mechanical and chemical stability of composites by preventing the aggregation of CoP nanoparticles during the OER process.