We characterize the dynamics of secular stagnation as a permanent regime switching from a full employment equilibrium to an underemployment equilibrium. In the latter, the natural interest rate is negative, and the economy is in deflation. Due to the non negativity condition imposed on policy rate, the zero lower bond (ZLB) applies which prevents targeting inflation. The secular stagnation equilibrium is achieved in a standard overlapping generations model with capital accumulation where two market imperfections are introduced: credit rationing and downward nominal wage rigidity. We then show that an aging population can bring the economy back into secular stagnation. To figure out how to escape the secular stagnation trap, we study the impact of transfers from workers to retirees. By lowering savings incentives, they can help the economy get out of the secular stagnation trap. In addition, they can be Pareto improving even if their return, the population growth rate, is lower than the savings return, the interest rate.