This article studies optimal leader‐follower affine formation control for linear multi‐agent systems, which has more formation flexibility due to the usage of stress matrices. First, based on the inverse optimality strategy, an affine formation control law is designed to drive the followers to their target positions, in which a corresponding performance index is minimized. Next, to minimize a prespecified performance index, another class of optimal affine formation control law is proposed by using a cooperative estimator. The design of the cooperative estimator is based on the proportional‐integral feedback which estimates the target position of each follower. Under the proposed control law, the followers achieve the target formation and the given performance indices are guaranteed to be optimal at the same time. Finally, the corresponding simulations are carried out to verify the effectiveness of the presented approaches.