The proton exchange membrane fuel cell (PEMFC) is a favorable renewable energy source to overcome environmental pollution and save electricity. However, the mathematical model of the PEMFC contains some unknown parameters which have to be accurately estimated to build an accurate PEMFC model; this problem is known as the parameter estimation of PEMFC and belongs to the optimization problem. Although this problem belongs to the optimization problem, not all optimization algorithms are suitable to solve it because it is a nonlinear and complex problem. Therefore, in this paper, a new optimization algorithm known as the artificial gorilla troops optimizer (GTO), which simulates the collective intelligence of gorilla troops in nature, is adapted for estimating this problem. However, the GTO is suffering from local optima and low convergence speed problems, so a modification based on replacing its exploitation operator with a new one, relating the exploration and exploitation according to the population diversity in the current iteration, has been performed to improve the exploitation operator in addition to the exploration one. This modified variant, named the modified GTO (MGTO), has been applied for estimating the unknown parameters of three PEMFC stacks, 250 W stack, BCS-500W stack, and SR-12 stack, used widely in the literature, based on minimizing the error between the measured and estimated data points as the objective function. The outcomes obtained by applying the GTO and MGTO on those PEMFC stacks have been extensively compared with those of eight well-known optimization algorithms using various performance analyses, best, average, worst, standard deviation (SD), CPU time, mean absolute percentage error (MAPE), and mean absolute error (MAE), in addition to the Wilcoxon rank-sum test, to show which one is the best for solving this problem. The experimental findings show that MGTO is the best for all performance metrics, but CPU time is competitive among all algorithms.