Conjugated microporous polymers (CMPs), featuring photoactive structures, a high surface area, robust thermal stability, and facile modulation, provide a versatile platform for fabricating diverse heterogeneous photocatalysts. The incorporation of donor-acceptor (D-A) structures into CMPs to increase their charge separation potential and enhance the photocatalytic efficacy is a viable strategy. In this work, we designed and synthesized a unique set of D-A monomers, incorporating boranil dyes as electron-deficient moieties and carbazoles as electron-rich subunits. Subsequently, D-A CMPs were prepared via an economical and environmentally friendly oxidation coupling reaction, and their potential in photocatalytic oxidation reactions was investigated. Modulation of the polymer's photoelectronic properties and photocatalytic performance can be achieved by adjusting the boranil content in the monomer. The polymer pCZFB-3, with the highest content of boranil units, exhibited an optimal photocatalytic activity. This finding confirms that strengthening the D-A effect can significantly enhance a catalyst's photoelectronic properties and catalytic efficacy. This study presents insights into designing innovative heterogeneous photocatalysts based on boron-containing dyes.