Renewable energy sources (RES) are becoming more popular globally as a reaction to critical energy concerns. Modern energy management technologies are used to maximize their efficiency while preserving the reliability of the grid. A hybrid energy storage system (HESS) connects to the DC microgrid through the bidirectional converter, allowing energy to be transferred among the battery and supercapacitor (SC). In this paper, a fuzzy logic control (FLC) technique is developed for PV-based DC microgrid systems that use both batteries and SCs. The proposed method uses the unbalanced energy from the battery pack to enhance the overall effectiveness of the HESS. The FLC approach is performed to validate under conditions of variable irradiance using MATLAB Simulink. When sudden changes in irradiance occur, the proposed FLC brings the voltage back to the desired level in terms of transient response like 33 ms settling times and 19% overshoot values. The results exhibit that the proposed method is more efficient in terms of time response, power output, increasing battery life, and ensuring a continuous supply of the PV system.