[1] The complex behavior of photochemical pollutants in the northwestern Mediterranean basin (NWMB) is conditioned by the superposition of circulations of different scale and the pattern of emissions. Therefore a new approach to the modeling of air quality in the NWMB has been adopted by combining the global climate-chemistry model ECHAM5/ MESSy and the regional modeling system MM5-EMICAT2000-CMAQ to analyze the high levels of photochemical air pollution during a typical summertime episode. We show that this combination of models is well suited to address the range of scales involved. The complexity of the area requires the application of high spatial and temporal resolution (2 km and 1 hour) modeling to cover local to regional interactions. We address the local and largescale processes controlling tropospheric ozone in the NWMB, notably emissions and photochemistry, convective and advective transport, deposition processes, and stratospheretroposphere exchange. The simulation results indicate that the ozone buildup largely results from local photochemical production, which strongly exceeds the removal rates through transport and deposition. The contribution by advective transport is limited, associated with the stagnant meteorological conditions. In the lower troposphere, local recirculation systems are of key importance. The strength of the land-sea breeze circulation and thermally or mechanically driven convection over the complex orography of the eastern Iberian coast can induce vertical transport and the layering of air pollution.