Context. Hydrogen-dominated atmospheres of hot exoplanets expand and escape hydrodynamically due to the intense heating by the X-ray and extreme ultraviolet (XUV) irradiation of their host stars. Excess absorption of neutral hydrogen has been observed in the Lyα line during transits of several close-in gaseous exoplanets, indicating such extended atmospheres. Aims. For the hot Jupiter HD 189733b, this absorption shows temporal variability. Variations in stellar XUV emission and/or variable stellar wind conditions have been invoked to explain this effect. Methods. We apply a 1D hydrodynamic planetary upper atmosphere model and a 3D MHD stellar wind flow model to study the effect of variations of the stellar XUV irradiation and wind conditions at the planet's orbit on the neutral hydrogen distribution, including the production of energetic neutral atoms (ENAs), and the related Lyα transit signature. Results. We are able to reproduce the Lyα absorption observed in 2011 with a stellar XUV flux of 1.8×10 4 erg cm −2 s −1 , rather typical activity conditions for this star. Flares with parameters similar to the one observed 8 h before the transit are unlikely to have caused a significant modulation of the transit signature. We find that the resulting Lyα absorption is dominated by atmospheric broadening, whereas the contribution of ENAs is negligible. Thus, the absorption does not depend on the stellar wind parameters. Conclusions. Since the transit absorption can be modeled with typical stellar XUV and wind conditions, it is possible that the nondetection of the absorption in 2010 was affected by less-typical stellar activity conditions, such as a very different magnitude and/or shape of the star's spectral XUV emission, or temporal/spatial variations in Lyα affecting the determination of the transit absorption.