The goal of the present work is to simulate through a commercial CFD code the flow within the headlamp, including the condensation process in the lens of the headlamp. Considering the results, it has been possible to obtain a better comprehension of the condensation process, temperature profile and moist air flow inside the headlamp. Looking for the upgrade in headlamps designs, a mathematical model able to represent the water fogging and defogging conditions on the lens of automotive headlamp was develop. The proposed model represents evaporation and condensation of water film on specified walls. Relative humidity profile within the headlamp has also been analyzed, evaluating the regions where the moisture is closer of the saturation condition. The obtained results in simulation have been in concordance with expected ones, showing the same condensation regions observed in the experimental tests performed by the automaker. Based on this comparison, is has been possible to validate CFD techniques aiding engineers in the design of this important automotive equipment.