Design of cost-effective bifunctional electrocatalysts for both the oxygen evolution reaction (OER) and hydrogen evolution reaction (HER) is vital for developing hydrogen energy for the future. Herein, a cost-effective phosphorus-doped Co-Fe-B material with chain-like structure (denoted as Co1-Fe1-B-P) is reported as an efficient and novel bifunctional electrocatalyst for the OER and HER, and was produced via a facile water-bath synthesis and subsequent phosphorization. For the OER, the as-prepared Co1-Fe1-B-P nanochains require an extremely low overpotential of about 225 mV at 10 mA cm-2 and possess a small Tafel slope of 40 mV dec-1 in alkaline media. Impressively, the HER properties of Co1-Fe1-B-P nanochains are superior to those of P-free Co-Fe-B in terms of overpotential at 10 mA cm-2 (173 mV vs. 239 mV) and kinetic Tafel slope (96 mV dec-1vs. 105 mV dec-1). The synergetic effect between Co-Fe-B and doped-P is mainly responsible for the satisfactory bifunctional performance, while the one-dimensional (1D) chain-like structure endows Co1-Fe1-B-P with abundant catalytically active sites that enhance the atom utilization efficiency. Moreover, the developed Co1-Fe1-B-P nanochains can be simultaneously utilized as both the cathode and anode for overall water-splitting, which requires a cell voltage of only 1.68 V to deliver 10 mA cm-2. This work provides a feasible and promising protocol to realize metal borides as efficient electrocatalysts in energy-related applications.