The goal of this paper is to present an algorithm for increasing output power in wind farms with high wake losses. In some wind directions, wake effects cannot be neglected because the distance between turbines may be less than 5–8 times of rotor diameter. The purpose of presented algorithm is to determine coefficient of performance (C P ), thrust coefficient (C T ), pitch angle (β) and rotational speed (ω) of each turbine by using wake effects equations so that wake losses in the wind farm becomes minimum which result in increasing output power of wind farm. PSO algorithm is used for optimization. Finally, a sample wind farm consisting of 16 turbines is used as a case study and the results show that there is a noticeable increase in the amount of wind farm output power rather than the time which no control and optimization is used. The conclusion is that the presented algorithm is suitable for wind farms with high wake losses and little distance between their turbines and is very effective for increasing their output power.