Given an automorphism $\tau$ of a compact group $G$, we study the factorization of $C(\tau,K)$, the contraction group of $\tau$ modulo a closed $\tau$-invariant subgroup $K$, into the product $C(\tau)K$, of the contraction group $C(\tau)$ of $\tau$, and $K$. We prove that the factorization $C(\tau,K)=C(\tau)K$ holds for every closed $\tau$-invariant subgroup $K$ if and only if $G$ contains arbitrarily small closed normal $\tau$-invariant subgroups $N$ with finite-dimensional quotients $G/N$. For metrizable groups, we obtain that $C(\tau)K$ is a dense subgroup of $C(\tau,K)$, for every closed $\tau$-invariant subgroup $K$. These results are used to link the contraction group to the properties of the dynamical system $(G,\tau)$. It follows that $\tau$ is distal if and only if $C(\tau)$ is trivial, while ergodicity of $\tau$ implies that $C(\tau)$ is nontrivial. When $G$ is metrizable, the closure of $C(\tau)$ is the largest closed $\tau$-invariant subgroup on which $\tau$ acts ergodically and, at the same time, it is the smallest among closed normal $\tau$-invariant subgroups $N$ such that $\tau$ acts distally on $G/N$. If $\tau$ is ergodic, then its restriction to any closed connected normal $\tau$-invariant subgroup $N$ with finite-dimensional quotient $G/N$ is also ergodic. Moreover, when $G$ is connected, the largest closed $\tau$-invariant subgroup on which $\tau$ acts ergodically is necessarily connected.