In this paper, a study on formation of polymer‐containing oily sludge (PCOS) produced during polymer‐containing oily wastewater (PCOW) treatment was carried out. First, the composition of PCOW and PCOS was compared. The results showed that not all the oil in PCOW transferred into the PCOS and the water‐insoluble polymer in PCOS was the mixture of residual polymer (HMPAM) after the polymer flooding and cationic flocculant (CPAM) using for treating wastewater. Then, flocculation and zeta potential tests presented that hydrophobic water‐insoluble polymer was formed by electrostatic neutralization between HMPAM and CPAM. At last, dual‐polarization interferometry (DPI) tests were innovatively used to investigate the interaction between the water‐insoluble polymer and oil components. The results revealed that the order of interaction between water‐insoluble polymer and oil components was saturate < aromatic < resin < asphaltene. In one word, the PCOS was formed by interactions among HMPAM, CPAM and some oil components, especially the asphaltene, resin, and aromatic.