As well as issuing new shares, companies sometimes buy back existing ones.
Updated March 2019
There are two main ways for a company to return cash to its shareholders (other than selling itself and returning the cash to its owners). One is to pay a dividend. The other is for the company to use the money to buy back its own shares and cancel them. This leaves the shareholders who don't sell with a bigger chunk of the company than before.
So you could argue that if an investor reinvests their dividends, and that buybacks and dividends are treated equally by the tax authorities (not always the case), and that they happen at the same time, then they are the same thing. The end result is that the investor owns a bigger chunk of the company than before.
In reality, there are differences in tax treatment that can make buybacks more appealing for some investors. But that aside, as financial analyst and author Michael Mauboussin pointed out in a piece on buybacks written for Credit Suisse in 2014 (they've been controversial for a while), "the most fundamental difference between buybacks and dividends may be the attitude of executives". Management teams hate cutting dividends because they know investors hate it. As a result, dividend payouts are less volatile (they go up and down a lot less) than share prices. But buybacks are more flexible they fall when the market falls, and rise when it goes up.
It's this element of discretion that makes us favour dividends over buybacks. As noted above, management teams are no better at market timing than other investors. Throw in the added distraction (for some) of being able to influence their pay packets by boosting buybacks, and you have a recipe for poor decision making. Dividends are transparent and impose an element of discipline; buybacks are often opaque and overly manipulable. Given that we're dealing with human beings, we know what we prefer.