Photocatalytic hydrogen (H2) evolution from water is considered as a prospective approach, which can convert inexhaustible solar energy into chemical energy to alleviate energy crisis and environmental problems. Herein, the N-defective g-C3N4 with porous structure was firstly synthesized in a sealed crucible by one-step thermal polymerization method. The experimental data showed that the yield of the catalyst was obviously increased under sealing condition. Moreover, the N-defective g-C3N4 prepared from urea precursor under sealed condition reached an optimum photocatalytic H2 production rate of 597.4 mmol/h and an apparent quantum efficiency of 15.6% at wavelength of 420 nm. This enhanced photocatalytic H2 production performance is mainly ascribed to the introduction of N-defects, which not only extended of the visible light absorption, but also acted as the electron trap centers to suppress the recombination of the photogenerated electron and hole pairs. This work offers one-step facile strategy for the introduction of N-defects to prepare N-defective g-C3N4 with superior photocatalytic activity, which is also a great substitute for the high-energy consuming and complicated synthetic routes.