In this paper, an advanced and modified MRAS technique is utilized for controller design in electric power systems. The weighting factors of the proposed MRAS are tuned by using PSO. This optimal-adaptive controller is also normalized by normalization techniques to guarantee the system stability. The proposed MRAS then is applied to design STATCOM stabilizer and UPFC power flow controller. STATCOM stabilizer is a regulatory controller, while the power flow controller of UPFC is a tracking one. Therefore, the ability of the proposed MRAS technique to design regulatory and tracking controllers is investigated. In order to indicate the effectiveness of the proposed method, it is evaluated against the conventional methods. Simulation results demonstrate the validity of the method, under uncertainties and different disturbances.