This paper presents a novel heuristic based adaptive control technique (ACT) for improved compensation capability of the unified power quality conditioner (UPQC). The compensation capability of UPQC is enhanced by the optimal regulation of DC link voltage. Among all power quality (PQ) distortions, voltage sag is the severe PQ problem that significantly deteriorates the regulation of DC link voltage. The conventional approaches utilize a fixed gain PI controller that increases the error between the reference and actual DC link voltage under sag condition. This ultimately results in poor compensation of PQ distortions at the point of common coupling. To enhance compensation capability, the performance of ACT is examined with analytical and artificial intelligence techniques. The model reference adaptive system (MRAS) is used in the analytical method for online self tuning PI controller. For artificial intelligence technique, the off-line trained ANFIS is processed in the simulation studies. The performance of ACT based UPQC is validated in Matlab/Simulink and the obtained results are compared with conventional scheme. To substantiate theoretical results of the proposed approach, the algorithm is tested in real time Xilinx system generator (XSG).