The appetite for funds with capital protection has been increasing in recent years. This paper investigates the optimal design of such funds, which provide capital protection at a specific maturity. Capital protection is often set at 100% at inception for simplicity's sake, but without any clearer rationale. We propose a framework for estimating the optimal level of protection or, equivalently, the optimal level of the cushion that maximizes investor utility while taking into account the aversion of that same investor to risk or loss. The optimal management rule that we call portfolio insurance with adaptive protection offers the right trade-off between upside potential and capital protection at the maturity. Under this strategy, the cushion is capped at a predefined level. Should the cushion increase too much, the upside potential would become very large - too large compared with the protection at maturity. Higher utility would then be obtained by increasing the protection rather than letting the cushion drift higher. Initial protection should therefore be above/below 100% for high/low interest rates and protection should be increased over time if the cushion becomes larger than the predefined cap.