We examine the economic mechanisms that limited arbitrage between the cash and forward markets of agency MBS, and whether asset purchases of the Federal Reserve (Fed) alleviated price dislocations. We ﬁnd that the cash-forward basis, or the price diﬀerence between the cash and forward markets of agency MBS controlling for diﬀerences in fundamentals, widened signiﬁcantly by $0.9 per $100 face value during the height of the COVID-19 crisis. The widening basis was accompanied by a signiﬁcant increase in selling by customers in the cash market, indicating a “scramble-for-cash” following the liquidity shock. Dealers provided liquidity by increasing both their long cash and short forward positions signiﬁcantly but the basis continued to widen, implying that balance sheet costs constrained dealers’ inventories. We estimate dealers’ average costs of holding inventory for ﬁve weeks as about $0.8. We also ﬁnd that primary dealers aﬃliated with banks subject to Basel III liquidity regulations increased their positions more than others. The basis narrowed by about $0.7 following the Fed’s MBS purchases in the forward market. We attribute this eﬀect to the faster settlement schedules of the Fed’s purchases, compared to the market convention, which allowed a faster deployment of capital. Overall, our results show that the combined liquidity constraints of investors and dealers led to severe price dislocations, and the Fed, in its role as the “dealer of last resort,” absorbed the liquidity demand that dealers lacked the capacity to meet.