Conjugated donor (D)–acceptor (A) polymer heterojunctions have developed as attractive photocatalysts. However, it is a great difficulty in precisely keeping the batch-to-batch reproducibility of polymers and controlling the related photocatalytic activity. Herein, three ladder-like small molecules BTx (BT2F, BTORCAE, and BTORIC2Cl) are synthesized via molecular engineering and the corresponding BTx/g-C3N4 heterojunctions are developed as photocatalysts for sterilization and contaminant degradation. It is demonstrated that employing another A unit into the D–A–D backbones of the small molecule could promote its intramolecular charge transfer and also improve the intermolecular charge transfer. Notably, BTORIC2Cl employing 2-(5,6-Dichloro-3-oxo-2,3 dihydro-1H-inden-1-ylidene)malononitrile as A1 unit in its symmetric A1–D–A2–D–A1 structure displays near-infrared absorption and extends the absorption edge of BTORIC2Cl/g-C3N4 to 850 nm. With the synergy of efficient intermolecular charge transfer, BTORIC2Cl/g-C3N4 contributes the champion photocatalytic activity of 98.9 % and 99.6 % antibacterial rates for Staphylococcus aureus and Escherichia coli. Moreover, the highest degradation reaction rate constant for Rhodamine B obtained by BTORIC2Cl/g-C3N4 is 5.7 times that of g-C3N4. This study proposes new ideas of fabricating small molecules/g-C3N4 OSHJs as photocatalysts via rational molecular engineering.