In this paper, the flexible polyacrylonitrile (PAN) nanofibers are used as carriers to prepare one-dimensional bismuth oxyiodide-silver iodide (BiOI-AgI) photocatalyst. PAN-BiOI-AgI is prepared on the surface of electrospun PAN nanofibers by alternate growth method and subsequent ion exchange method at room temperature. The results of XRD, TEM, XPS, and UV-Vis diffuse reflectance spectroscopy indicate the heterojunctions formation. The flexible PAN-BiOI-AgI heterojunction fibers show higher photocatalytic degradation efficiency for rhodamine B than PAN-BiOI or PAN-AgI. The enhanced photocatalytic performance is attributed to that the heterojunction improves the photo-generated electron-hole separation efficiency. After 60 min of visible light irradiation, the degradation efficiency is greater than 95%. Free radical capture experiments show that•O2- and h+ are the main groups involved in the oxidation reaction.