CO2 injection into shale reservoirs has been recognized as one of the most promising techniques for enhanced oil recovery and carbon capture, utilization, and storage. However, the omnipresent nanopores and the water films formed near the pore walls affect the understanding of mechanisms of CO2 regulating crude oil mobility in shale nanopores. In this work, we employ molecular dynamics simulations to study the occurrence and flow of CO2 and octane (nC8) mixtures in quartz nanopores containing water films, to illustrate the impact mechanisms of CO2 on nC8 mobility. The results indicate that nC8 exists between water films, and CO2 is mainly miscible with nC8 in the pore center, and a small portion of it accumulates at the interface between nC8 and the water film. CO2 significantly decreases the apparent viscosity of nC8 in both the bulk nC8 region and the nC8–water interface region, improving nC8 fluidity. As the percentage of CO2 in the CO2 and nC8 mixtures increases from 0 to 50%, the mean flow velocities of nC8 in the bulk phase region and the nC8–water interface region increase by 92.85 and 60.64%, respectively. Three major microscopic mechanisms of CO2 improving nC8 fluidity in quartz nanopores with water films are summarized: (i) CO2 reduces friction between nC8 and the water film by increasing the angle between nC8 molecules and the plane of the water film; (ii) CO2 widens the distance between nC8 molecules, causing the volume expansion of nC8 and its viscosity reduction; (iii) CO2 significantly increases the most probable and average velocities of nC8 molecules, thus improving their mobility. Our results enhance the comprehension of how CO2 facilitates oil flow in water-bearing shale reservoirs and the exploitation of unconventional oil resources.