In this paper, we study the symmetry properties of nondegenerate critical points of shape functionals using the implicit function theorem. We show that, if a shape functional is invariant with respect to some one-parameter group of rotations, then its nondegenerate critical points (bounded open sets with smooth enough boundary) share the same symmetries. We also consider the case where the shape functional exhibits translational invariance in addition to just rotational invariance. Finally, we study the applications of this result to the theory of one/two-phase overdetermined problems of Serrin-type. En passant, we give a simple proof of the fact that, under suitable smoothness assumptions, the ball is the only nondegenerate critical point of the Lagrangian associated to the maximization problem for the torsional rigidity under a volume constraint. We remark that the proof does not rely on either the method of moving planes or rearrangement techniques.