In this paper, we extend to the non-Hille–Yosida case a variation of constants formula for a nonautonomous and nonhomogeneous Cauchy problems first obtained by Gühring and Räbiger. By using this variation of constants formula, we derive a necessary and sufficient condition for the existence of an exponential dichotomy for the evolution family generated by the associated nonautonomous homogeneous problem. We also prove a persistence result of the exponential dichotomy for small perturbations. Finally, we illustrate our results by considering two examples. The first example is a parabolic equation with nonlocal and nonautonomous boundary conditions, and the second example is an age-structured model that is a hyperbolic equation.