How does the belief that policymakers will bail out investors in the event of a crisis affect the allocation of resources and the stability of the financial system? I study this question in a model of financial intermediation with limited commitment. When a crisis occurs, the efficient policy response is to use public resources to augment the private consumption of those investors facing losses. The anticipation of such a bailout distorts ex ante incentives, leading intermediaries to choose arrangements with excessive illiquidity and thereby increasing financial fragility. Prohibiting bailouts is not necessarily desirable, however: it induces intermediaries to become too liquid from a social point of view and may, in addition, leave the economy more susceptible to a crisis. A policy of taxing short-term liabilities, in contrast, can correct the incentive problem while improving financial stability.