The lifespan of a mosquito depends on several factors, including species, environmental conditions, and access to resources like food and water. Generally, the life expectancy of a mosquito ranges from a few days to several weeks. Females typically live longer than males because they need to survive long enough to lay eggs. For instance, the Aedes aegypti mosquito, known for transmitting diseases like dengue fever and Zika virus, may live for two to four weeks in optimal conditions.