A very simplified version of what's going on is the company raises capital by selling a portion of itself (an ownership stake) to the investors — the first purchasers of the stock. The existing owners allow this in the belief the capital raised from this _one time sale_ will be used to increase the value of the company enough so they are better off than before. This kind of thing must be approved by the company's board of directors, which exists to act on behalf of the shareholders rather than the management team or employees. 

When you buy a stock, you're buying a very small ownership stake in the company<sup>1</sup>. Buy enough of a company's stock, and you get a say in who gets to sit on the board of directors for the company, and therefore a say in what the company does and how it behaves, or even a potential claim on its assets. This is part of what gives a stock value on the open market<sup>2</sup>. But the money went to the previous owner of the stock, which is usually not the company itself. 

The other way a stock has value is through dividends. A business exists to make money for it's owners. That is it's purpose. Large public corporations are no exception, and they do this by sometimes taking a portion of their profits and paying it out to shareholders. That is a dividend. So owning the right stocks means sometimes getting "free" money above and beyond the value of the stock itself. A stock with a reputation for paying dividends may have more demand, and therefore a higher stock price<sup>3</sup>. 

But the important thing to understand relative to this question is the stocks are a one-time sale for the company. The company receives capital once from the initial sale, and doesn't get any input or return when (or if!) the stocks are bought/sold afterwards. 

The company does still care about the stock price, though, because of the shareholders who own those stocks (and therefore own the company). If the stock performs poorly, the shareholders will get the board to replace the company's management team (by first replacing board members if necessary). Or they'll sell the stock in order to purchase another stock that is more valuable, which helps the stock price trend lower-still, which will further encourage other shareholders to take action. 

The other thing that can happen if the stock prices trends too low is the company becomes vulnerable to take-over by a rival. Remember ownership of stock is ownership of the company, and a rival need only purchase 51% of the stock to control the board &mdash; often even less if there is a sympathetic investor with the ailing company. Thus a low stock price can be dangerous for a company's very existence. 

In other words, if a C-level executive wants to keep that nice six or seven figure salary, they better keep that stock price healthy<sup>4</sup>. 

Of course, you, I, or any other average Joe are unlikely to ever reach the level where we have a meaningful reason to attend a shareholders meaning and actually vote on anything that matters to us<sup>5</sup>. We don't really care about the ownership stake so much. We _do care_ that stocks have shown stable and even increasing value over time. This makes them a useful place to park savings, that might even provide a good return. 

As a practical matter, the stock market as a whole cannot indefinitely out-perform the general economy, relative to the portion of said economy devoted to investment practices. Over time the stock market and larger economy should rise or fall at about the same rate. But there are variances between the two, and individual investors can sometimes do very well for themselves this way. Sometimes the tail can even wag the dog, and investment behavior can actually spur real economic growth or decline.


<sub>1. This is gross over-simplification. In reality, there are different classes of stock, and the casual investor rarely ends up with stock that grants any meaningful ownership interest</sub>  
<sub>2. This has interesting implications in the face of investment vehicles like mutual funds, where you don't own shares in the fund companies directly. Instead, you own a share in the fund. You give up any ownership voting rights you may have had, and instead help the fund managers (often banks) amass larger stakes in a company than they could using their own money.</sub>  
<sub>3. In practice, dividends also have some negative attributes, such as higher tax rates, that don't attract as many investors as you might think.</sub>  
<sub>4. "Healthy" here means not simply stable, but _steadily increasing_. Once a company sells itself in this way, where ownership in the company has primarily become an investment vehicle, it's no longer good enough for a company to be simply stable and profitable. If a company is not also _growing_ as quickly as it can, it's in trouble. More than that, just showing good growth is often not enough. It must also _beat expectations_ to keep investors happy, because stock prices have often already accounted for expected growth. To raise the price further, you must _exceed_ your own projections, which were already often optimistic in order to keep investors happy in the first place. This never-easing pressure has a profound impact on how corporations behave.</sub>  
<sub>5. The prevalence of small investors can have an interesting impact on corporate ownership structures. If most of a company's stock is spread around among these small investors, a comparatively small investment stake in a company might be enough to effectively control it. Think about this point some more in relation to footnote #2.</sub>