A real-world example of buying to cover
One of the big stock market stories of 2021 was the incredible share price rally of video game retailer GameStop (GME -3.77%). GameStop is a troubled company that's been struggling for years, and its future is very much in doubt. Investors believing that GameStop's share price would decline shorted the stock by borrowing shares and reselling from their brokers.
Speculators in early 2021 generated enthusiasm for the stock, which had the effect of pushing the stock's price dramatically higher. Fearing further losses as the stock's price soared, many investors who had sold GameStop stock short rushed to buy shares to cover their short positions.
The GameStop situation is notable because so many investors rushed to buy to cover their short positions that a short squeeze occurred. A spike in buying to cover caused demand for the company's shares to exceed the supply available in the open market, which has the effect of further boosting the share price and causing exponentially rising panic among short sellers struggling to buy to cover their shorts.
Most investors never choose to short a stock and thus never need to buy to cover. But if shorting a stock is appealing to you, then it's important to understand how buying to cover works.