I'm trying to understand the extension risk associated with interest only bonds in a CMO. When rates rise, prepayments drop, and so the life of the IO bonds is extended. This causes the value of the IO to increase because investors receive more interest. But doesn't extension risk play a role since investors are missing a chance to invest in a higher rate environment?
No, for an IO bond, if someone pre-pays the entire mortgage, the payments (and therefore interest) stop. If you bought an IO bond today and immediately after all of the debt is pre-payed, you lose your entire investment. Extension risk is the risk that cashflows are delayed. For an IO, you want them to last as long as possible.
However, when interest rates are high, duration can still be positive. If at current interest rates expected prepayments are zero, an increase in interest rates would reduce the price (same cash flows discounted at a higher rate).
For a PO bond, extension risk is important. The total payments you will receive are fixed. For any positive interest rate, you would prefer to receive the payments sooner rather than later and would be harmed by a slowdown in payoff rates.