The step-like scheme (S-scheme) heterojunction photocatalyst, which possess an improved electric field, intimate interfacial contact and reasonable energy band structure, is one of the most optimal ways to solve the wastewater problem caused by residual antibiotics. Herein, a new type of S-scheme 0D/2D Co2ZrO5/g-C3N4 (CZO/CN) heterojunction photocatalyst was prepared via an ultrasonic assisted hydrothermal method and used as photocatalyst to degrade tetracycline (TC, 20 mg/L, 100 mL). Compared to pure CN and CZO, the CZO/CN with the optimal design proportion (30CZO/CN) demonstrates the outstanding photocatalytic efficiency for TC degradation under visible-light irradiation, with the degradation rate being 94.8 % within 180 min at pH 5.0. Moreover, the 30CZO/CN exhibits superior stability, which still eliminated 90 % of TC after five times cycle runs. Furthermore, the S-scheme mechanism of photocatalytic TC removal by CZO/CN is proposed by XRD, FT-IR, XPS, UV–Vis DRS and PL analysis, which summarized that the enhanced photocatalytic activity of CZO/CN was mainly ascribed to its larger specific surface area, available light absorption region and appropriate bandgap width, dominated by the S-scheme pattern. This study presents a novel S-scheme g-C3N4-base heterojunction photocatalyst can effectively treat wastewater and provides design ideas for other heterojunctions.