<p>In the equatorial Pacific, air–sea CO<sub>2</sub> flux is known to fluctuate in response to inherent climate variability, predominantly the El Niño–Southern Oscillation (ENSO). For both investigation of the response of the carbon cycle to human-induced radiative perturbations and prediction of future global CO<sub>2</sub> concentrations, representation of the interannual fluctuation of CO<sub>2</sub> fluxes in Earth system models (ESMs) is essential. This study attempted to reproduce observed air–sea CO<sub>2</sub> flux fluctuations in the equatorial Pacific using two ESMs, to which observed ocean temperature and salinity data were assimilated. When observations were assimilated into an ESM whose inherent ENSO variability was weaker than observations, nonnegligible correction terms on the governing equation of the equatorial ocean temperature caused anomalously false equatorial upwelling during El Niño periods that brought water rich in dissolved inorganic carbon from the subsurface layer to the surface layer. Contrary to observation, this resulted in an unusual upward air–sea CO<sub>2</sub> flux anomaly that should not occur during El Niño periods. The absence of such unrealistic upwelling anomalies in the other ESM with the data assimilation reflects better representation of ENSO and the mean thermocline in this ESM without data assimilation. Our results demonstrate that adequate simulation of ENSO in an ESM is crucial for accurate reproduction of the variability in air–sea CO<sub>2</sub> flux and hence, in the carbon cycle.</p>