What is the optimal consumer bankruptcy law? I examine this question in the context of an incomplete markets lifecycle model with a planner who can choose state-contingent bankruptcy costs. I develop two key theoretical characterizations. First, the optimal policy has a bang-bang property: The...