This study presents a voltage source converter (VSC) control of solar photovoltaic (PV)-battery-based three-phase grid interfaced microgrid. This microgrid is controlled to operate in an autonomous mode and the grid-connected mode. In grid integrated mode, the control aims to improve the power quality of the grid current and to ensure the unity power factor operation at the grid. Therefore, in the grid-connected mode, the improved zero attracting quaternion-valued least mean square (IZAQLMS) control approach with high DC offset rejection capability is used. Owing to this, the reference grid currents become immune to harmonics and DC-offset. The control strategy takes power management into account and additionally assists several vital functions such as compensation of reactive power, power factor correction, and harmonics mitigation. This control scheme also ensures the stable system operation in autonomous mode following an unexpected incident deprived of collapse owing to the grid failure and discrepancy in the generation and load demand. In off-grid mode, the microgrid control generates a good quality of voltages and feeds the power to the load using the PV array and the battery. Simulated and test results on a laboratory prototype validates the effectiveness of the system.