Policy implications are derived for an inflation-targeting central bank, whose credibility is endogenous and depends on its past ability to achieve its targets. This is done in a New Keynesian framework with heterogeneous and boundedly rational expectations. We find that the region of allowed policy parameters is strictly larger than under rational expectations. However, when the zero lower bound on the nominal interest rate is accounted for, self-fulfilling deflationary spirals can occur, depending on the credibility of the central bank. Deflationary spirals can be prevented with a high inflation target and aggressive monetary easing.