We regulated the microstructure of BiOBr/BiOI to change its bandgap to be applicable to the synthesis of imines. Multiple characterization methods, including X-ray diffraction (XRD), scanning electron microscopy (SEM), transmission electron microscopy (TEM), X-ray photoelectron spectroscopy (XPS), Brunauer-Emmett-Teller (BET) analysis, UV–vis diffuse reflectance spectroscopy (DRS), photoluminescence (PL) spectroscopy and electrochemical impedance spectroscopy (EIS), were applied to elucidate the origin of the excellent photoactivity. A series of BiOBr/BiOI catalysts were applied to convert anilines into imines under visible light irradiation, and of the tested catalysts, BiOBr/BiOI-1/3 showed the highest activity. The conversion rate was 55.1% when using the physical mixture of BiOBr/BiOI at a molar ratio of 1/3, while the conversion rate reached 68.9% when using BiOBr/BiOI-1/3 heterojunctions, demonstrating that the heterojunction of BiOBr/BiOI is a key factor enhancing the conversion rate. The effects of different light intensities and wavelengths were explored. Moreover, the activity of the catalyst was stable after five cycles. O2−, h+, and e− were the main active substances in the trapping experiment of reactive species.