The three-phase contact line of a droplet on a smooth surface can be characterized by the Young-Dupré equation. It relates the interfacial energies with the macroscopic contact angle θe. On the mesoscale, wettability is modeled by a film-height-dependent wetting energy f(h). Macro- and mesoscale description are consistent if γ cos(θe) = γ+f(ha), where γ and ha are the liquid-gas interface energy and the thickness of the equilibrium liquid adsorption layer, respectively. Here, we derive a similar consistency condition for the case of a liquid covered by an insoluble surfactant. At equilibrium, the surfactant is spatially inhomogeneously distributed implying a non-trivial dependence of θe on surfactant concentration. We derive macroscopic and mesoscopic descriptions of a contact line at equilibrium and show that they are only consistent if a particular dependence of the wetting energy on the surfactant concentration is imposed.This is illustrated by a simple example of dilute surfactants, for which we show excellent agreement between theory and time-dependent numerical simulations.