Using Fitting's Lemma, one can give another version of the fine argument of @Tobias.
The sequence
$$
\ker(A) \subseteq \ker(A^2) \subseteq \ker(A^3) \subseteq \dots
$$
is ascending, and the sequence
$$
\operatorname{im}(A) \supseteq \operatorname{im}(A^2) \supseteq \operatorname{im}(A^3) \supseteq \dots
$$
is descending. Choose the smallest $m$ such that
$$
\ker(A^m) = \ker(A^{m+i}),
\qquad
\operatorname{im}(A^m) = \operatorname{im}(A^{m+i})
$$
for all $i \ge 0$. Note that if $\ker(A^m) = \ker(A^{m+1})$, then $\ker(A^m) = \ker(A^{m+i})$ for all $i \ge 0$. In particular $m \le n$.
Now Fitting's Lemma states that
$$
F^n = \ker(A^m) \oplus \operatorname{im}(A^m),
$$
and $A$ is nilpotent on the first summand, and invertible on the second one.
Then for any $k \ge m$ (actually, I believe, exactly for these values of $k$) we will have $$\operatorname{rank}(A^k) = \operatorname{rank}(A^{k+1}).$$