The heterostructure composed of lead chalcogenides (PbX, X=S, Se, Te) and halide perovskite CsPbI3 has recently emerged as a promising candidate for optoelectronic devices. This study uses theoretical investigations using first-principles calculations with the VASP software to understand the structural, electronic, and optical properties of the PbX(X=S, Se, Te)/CsPbI3 heterostructure. Appropriate lattice mismatch rates(4.6%, 2.4%, 3.8%) and similar octahedral frameworks are confirmed, ensuring the feasibility of constructing the PbX/CsPbI3 heterostructure. Electronic property calculations unveiled the physical mechanisms enhancing luminescence efficiency. The I-type band alignment at the PbX/CsPbI3 interface(-5.27eV<PbX<-3.73eV, -5.34eV<CsPbI3<-3.57eV) contributes to the reduction of electron and hole recombination losses, thereby enhancing energy transfer efficiency. This favorable arrangement facilitates the transfer of electrons and holes from the CsPbI3 layer to the PbX material, a conclusion supported by the difference in charge density. PbSe/CsPbI3 exhibited superior charge transfer capabilities among the three heterostructures, with electron clouds more pronounced than the others. The heterostructure extended the light absorption range of CsPbI3 from visible to near-infrared due to the influence of PbX. By comparing the absorption spectra's magnitude, this study finds that PbTe/CsPbI3>PbSe/CsPbI3>PbS/CsPbI3. PbSe/CsPbI3 performs best in terms of stability, charge density transfer, and optical properties. Furthermore, under the premise of ensuring stability, different optical absorption characteristics can be achieved by adjusting the composition of Se atoms in PbSe/CsPbI3. This work provides a theoretical basis for the physical mechanisms behind enhancing the performance of PbX/CsPbI3 heterostructures as visible-to-near-infrared optoelectronic materials. It offers a promising avenue for the design of high-performance visible-to-near-infrared optoelectronic materials.