When you short sell a stock, your broker will lend it to you.
The stock will come from the brokerage's own inventory, from
another one of the firm's customers, or from another brokerage
firm. The shares are sold and the proceeds are credited to your
account. Sooner or later, you must "close" the short by buying back
the same number of shares (called covering) and returning them to
your broker. If the price drops, you can buy back the stock at the
lower price and make a profit on the difference. If the price of
the stock rises, you have to buy it back at the higher price, and
you lose money.
http://www.investopedia.com/university/shortselling/shortselling1.asp