In this study, graphitic carbon nitride (g-C3N4) and niobium pentoxide nanofibers (Nb2O5 NFs) heterojunction was prepared by means of a direct electrospinning approach combined with calcination process. The characterizations confirmed a well-defined morphology of the g-C3N4/Nb2O5 heterojunction in which Nb2O5 NFs were tightly attached onto g-C3N4 nanosheets. Compared to pure g-C3N4 and Nb2O5 NFs, the as-prepared g-C3N4/Nb2O5 heterojunction exhibited remarkably enhanced photocatalytic activity for degradation of rhodamine B and phenol under visible light irradiation. The enhanced catalytic activity was attributed predominantly to the synergistic effect between g-C3N4 sheets and Nb2O5 NFs, which promoted the transferring of carriers and prohibited their recombination, confirmed by the measurement of transient photocurrent responses and photoluminescence spectra. In addition, the active species trapping experiments indicated that superoxide radical anion (·O2–) and hole (h+) were the major active species contributing to the photocatalytic process. With its high efficacy and ease of preparation, g-C3N4/Nb2O5 heterojunction has great potentials for applications in treatment of organic pollutants and conversion of solar energy.