This article proposes a novel predefined-time optimal formation control approach for second-order heterogeneous multiagent systems with nonlinear dynamics and external disturbances. Fuzzy logic systems are used to identify unknown nonlinearities. To enhance the system's robustness against external disturbances, an $H_\infty$ control strategy is implemented. The predefined-time optimal formation control method is developed by leveraging backstepping technology and actor–critic framework. This approach is designed to guarantee that the closed-loop system is practical predefined-time stable and $L_{2}$ -gain is less than or equal to a positive real number $\nu$ , and all system signals are predefined-time bounded while minimizing the cost of maintaining a formation pattern between the leader and followers. Simulation results validate the effectiveness and superiority of this control strategy.