The problem of real-time estimation of occupancy of buildings (number of people in various zones at every time instant) is relevant to a number of emerging applications that achieve high energy efficiency through feedback control. The measurement of CO2 concentration can be considered an important indicator that allows to define the occupation of closed and crowded spaces. Interesting cases can be school buildings and other buildings used in civil and residential (shopping centres, hospitals, etc.). This paper, starting from an experimental analysis in different classrooms of a University campus in real operating conditions, in different period of the year, proposes a possible correlation between CO2 concentration and the occupancy profile of the spaces. The acquired data are used to present some graphical correlations and to understand the most important variables or combination of them. Starting from an accurate analysis of the data, attempts are made to define a preliminary estimation method through the development of a mathematical models of occupancy dynamics in a building, which show interesting results.