The diurnal and vertical variability of heat and carbon dioxide (CO2) in the atmospheric surface layer are studied by analyzing measurements from a 213 in tower in Cabauw (Netherlands). Observations of thermodynamic variables and CO2 mixing ratio as well as vertical profiles of the turbulent fluxes are used to retrieve the contribution of the budget terms in the scalar conservation equation. On the basis of the daytime evolution of turbulent fluxes, we calculate the budget terms by assuming that turbulent fluxes follow a linear profile with height. This assumption is carefully tested and the deviation ftom linearity is quantified. The budget calculation allows us to assess the importance of advection of heat and CO2 during day hours for three selected days. It is found that, under nonadvective conditions, the diurnal variability of temperature and CO2 is well reproduced from the flux divergence measurements. Consequently, the vertical transport due to the turbulent flux plays a major role in the daytime evolution of both scalars and the advection is a relatively small contribution. During the analyzed days with a strong contribution of advection of either heat or carbon dioxide, the flux divergence is still an important contribution to the budget. For heat, the quantification of the advection contribution is in close agreement with results from a numerical model. For carbon dioxide, we qualitatively corroborate the results with a Lagrangian transport model. Our estimation of advection is compared with, traditional estimations based on the Net Ecosystem-atmosphere Exchange (NEE). Copyright 2008 by the American Geophysical Union.