We characterize the optimal default fund in a defined contribution (DC) pension plan. Using detailed data on individuals' holdings inside and outside the pension system, we find substantial heterogeneity within and between passive and active investors in terms of labor income, financial wealth, and stock market participation. We build a life-cycle consumption-savings model, with a DC pension account and an opt-out/default choice, that produces realistic investor heterogeneity. Relative to a common age-based allocation, implementing the optimal default asset allocation implies a welfare gain of 1.5% during retirement. Much of the gain is attainable with a simple rule of thumb.