To explore the photocatalytic performances and optoelectronic properties of pure and doped bismuth oxyhalides D-doped BiOX (D = Ag, Pd; X = F, Cl, Br, I) compounds, their atomic properties, electronic structures, and optical properties were systematically investigated using first-principles calculations. In previous experiments, the BiOX (X = Cl, Br) based system has been observed with enhanced visible light photocatalytic activity driven by the Ag dopant. Our calculations also show that the potential photocatalytic performance of Ag-doped BiOCl or BiOBr systems is enhanced greatly under visible light, compared with other Pd-doped BiOX (X = Cl, Br) compounds. Furthermore, it is intriguing to find that the Pd-doped BiOF compound has strong absorption over the infrared and visible light spectrum, which may offer an effective strategy for a promising full spectrum catalyst. Indicated by various Mulliken charge distributions and different impurity states in the gap when Ag or Pd was doped in the BiOX compounds, we notice that all D-doped BiOXs exhibit a p-type semiconductor, and all impurity levels originated from the D-4d state. The charge transfer, optoelectronic properties, and absorption coefficients for photocatalytic activities among D-doped BiOX photocatalysts caused by the electronegativity difference of halide elements and metal atoms will finally affect the photocatalytic activity of doped BiOX systems. Therefore, it is significant to understand the inside physical mechanism of the enhanced Ag/Pd-doped BiOX photocatalysts through density functional theory.