This paper proposes a novel hybrid optimization algorithm named GPOFWA, which integrates political optimizer (PO) with fireworks algorithm (FWA) to solve numerical and engineering optimization problems. The original PO uses subgroup optimal solutions such as party leaders and constituency winners to guide the movement of the search agent. However, the number of such subgroup optimal solutions is limited, which leads to insufficient global exploration capabilities of PO. In addition, the recent past-based position updating strategy (RPPUS) of PO lacks effective verification of the updated candidate solutions, which reduces the convergence speed of the algorithm. The proposed hybrid algorithm uses the spark explosion mechanism in FWA to perform explosion spark and Gauss explosion spark operations on the subgroup optimal solutions (party leader and constituency winner) respectively based on the greedy strategy, which optimizes the subgroup optimal solution and enhances the exploitative ability of the algorithm. Moreover, Gaussian explosion sparks are also used to correct the candidate solutions after RPPUS, which makes up for the shortcomings of the original PO. In addition, a new subgroup optimal solution called the Converged Mobile Center (CMC) based on two-way consideration is designed to guide the movement of search agents and maintain the population diversity. We test the presented hybrid algorithm on 30 well-known benchmark functions, CEC2019 benchmark functions and three engineering optimization problems. The experimental results show that GPOFWA is superior to many statE−of-thE−art methods in terms of the quality of the resulting solution.