The global shift towards decentralized energy systems, driven by the integration of distributed generation technologies and renewable energy sources, underscores the critical need for effective energy management strategies in microgrids. This study proposes a novel multi-objective optimization framework for grid-connected microgrids using quantum particle swarm optimization (QPSO) to address the dual challenges of minimizing operational costs and reducing environmental emissions. The microgrid configuration analyzed includes renewable energy sources like photovoltaic panels and wind turbines, along with conventional energy sources and battery storage. By incorporating quantum-inspired mechanics, QPSO overcomes limitations such as premature convergence and solution stagnation, often seen in traditional methods. Simulation results demonstrate that QPSO achieves a 9.67% reduction in operational costs, equating to savings of €158.87, and a 13.23% reduction in carbon emissions, lowering emissions to 513.70 kg of CO