For an affine algebraic variety X, we study the subgroup Aut alg (X) of the group of regular automorphisms Aut(X) of X generated by all the connected algebraic subgroups. We prove that Aut alg (X) is nested, i.e., is a direct limit of algebraic subgroups of Aut(X), if and only if all the G a -actions on X commute. Moreover, we describe the structure of such a group Aut alg (X).