"The Unified Power Flow Controller (UPFC) is one of the most promising Flexible AC Transmission Systems (FACTS) devices for the load flow control". Therefore, optimizing the position and size of UPFCs is a significant concern for raising the loading capability of the system. So far, several optimization approaches were introduced for resolving the issues in UPFC. Here, this work intends to establish a Bat Algorithm (BA) model for optimal sizing and positioning of UPFC to attain Optimal Power Flow (OPF). The deployed model is the improved edition of the conventional BA algorithm. Moreover, the objective specified for resolving the placement issue comprises of the reduction of cost and power loss. At last, the supremacy of developed model is evaluated over conventional models in terms of power loss. From the analysis, the performance of the implemented BA is 5% and 2.06% better than the compared ABC and GSA models.