We present an affine term structure model for the joint pricing of real and nominal bond yields that accounts for illiquidity. Using the model to adjust breakevens for inflation and liquidity risk substantially improves inflation forecasts. Our estimates imply that the Federal Reserve’s large-scale asset purchases lowered Treasury yields primarily by reducing real term premia. Real term premia also account for the positive response of long-term real forward rates to surprise changes in the federal funds target. Applying our model to U.K. data, we find that the inflation risk premium dropped significantly when the Bank of England formally adopted an inflation target.