Air pollution due to the presence of small particles and gases in the atmosphere is a major cause of health problems. In urban areas, where most of the population is concentrated, traffic is a major source of air pollutants (such as nitrogen oxides or hbox {NO}_x and carbon monoxide or CO). Therefore, for smart cities, carrying out an adequate traffic monitoring is a key issue, since it can help citizens to make better decisions and public administrations to define appropriate policies. Thus, citizens could use these data to make appropriate mobility decisions. In the same way, a city council can exploit the collected data for traffic management and for the establishment of suitable traffic policies throughout the city, such as restricting the traffic flow in certain areas. For this purpose, a suitable modelling approach that provides the estimated/predicted values of pollutants at each location is needed. In this paper, an approach followed to model traffic flow and air pollution dispersion in the city of Zaragoza (Spain) is described. Our goal is to estimate the air quality in different areas of the city, to raise awareness and help citizens to make better decisions; for this purpose, traffic data play an important role. In more detail, the proposal presented includes a traffic modelling approach to estimate and predict the amount of traffic at each road segment and hour, by combining historical measurements of real traffic of vehicles and the use of the SUMO traffic simulator on real city roadmaps, along with the application of a trajectory generation strategy that complements the functionalities of SUMO (for example, SUMO’s calibrators). Furthermore, a pollution modelling approach is also provided, to estimate the impact of traffic flows in terms of pollutants in the atmosphere: an R package called Vehicular Emissions INventories (VEIN) is used to estimate the amount of hbox {NO}_x generated by the traffic flows by taking into account the vehicular fleet composition (i.e., the types of vehicles, their size and the type of fuel they use) of the studied area. Finally, considering this estimation of hbox {NO}_x, a service capable of offering maps with the prediction of the dispersion of these atmospheric pollutants in the air has been established, which uses the Graz Lagrangian Model (GRAL) and takes into account the meteorological conditions and morphology of the city. The results obtained in the experimental evaluation of the proposal indicate a good accuracy in the modelling of traffic flows, whereas the comparison of the prediction of air pollutants with real measurements shows a general underestimation, due to some limitations of the input data considered. In any case, the results indicate that this first approach can be used for forecasting the air pollution within the city.