The development and wide spread of wind farms as a favorite and promising source of electrical energy in the world imposes its balanced compatibility with a set of economic, technical and environmental constraints. Manufacturing, installation, transportation, maintenance, and recycling end-of-life materials all contribute to CO2 emissions and lost expenses throughout the life cycle of a wind farm. These operations are the objective of an optimization work which serves to reduce the effect of these constraints on both the economic and ecological aspects of a wind farm. It has, therefore, become essential and urgent to improve the optimal performance, whether on the economic or environmental level, of these installations. With this in mind, the energy and financial success of any wind farm project is determined by a study to optimize sustainable operating efficiency based on the cost per kWh. In this article, we present a complete study on the life cycle of a wind farm in terms of ecological and economic costs. We studied the contributions of each phase of the life cycle in the economic and ecological costs of the wind farm. The intensities of these costs relative to the kilowatt-hour, produced by this source are evaluated and compared with those produced by conventional sources (gas and oil). The results show that the economic cost and the ecological impact are dependent on each phase of the onshore wind life cycle. Our results are presented for two cases, a real functional case and the case of several proposed scenarios applied to the same operating conditions of the real case. For the real case, the economic cost intensity was 0.029 $/kWh, while the environmental impact intensity was 0.012 kg CO2/kWh. The results also show that the manufacturing phase represents the most important contribution in economic and ecological costs in all scenarios including the real case. The lowest cost intensity and CO2 emission intensity are recorded for the 0.85 MW and 3 MW wind turbine classes, respectively.