When you own shares in a publicly held corporation, the equity figures provided in its financial statements are the company's accounting of what currently "belongs" to you and your fellow shareholders. Equity has three parts: contributed capital, retained earnings and other comprehensive income. A change in any results in a change to stockholders' equity.
Sales of Stock
The "contributed capital" segment of stockholders' equity represents how much money the company has received from selling stock to the public. If a company sells 1 million shares for $20 a piece, then contributed capital -- and thus equity -- increases by $20 million. Understand that this applies only to the company's sales of its own stock. When you buy a share of stock on the open market, you're almost invariably buying it from another investor, not the company itself. The money you pay doesn't go to the company. This is why day-to-day increases or decreases in the market price of shares have no effect on a company's stockholders' equity.
Just as stockholders' equity increases when a company sells stock, it decreases when that company buys stock back from the public. A company repurchasing shares is essentially giving money -- equity -- back to the stockholders. If the company buys back 1 million shares for $20 apiece, the company reports that value as a $20 million offset to contributed capital, thus reducing equity. If and when the company resells those "treasury" shares, contributed capital and equity go back up by whatever price the company got for them.
Profits and Losses
The retained earnings portion of stockholders' equity is simply all the profits the company has accumulated over the years, minus all the losses. If the company reports a $20 million profit and doesn't pay out a dividend, then retained earnings -- and thus equity -- increases by $20 million. Dividends to shareholders represent profits "intercepted" on their way to retained earnings. If a company reports a $20 million profit and pays $5 million in dividends, then equity increases by only $15 million, and a company that posted a $20 million loss in a year would see its equity decline by $20 million.
Adjustments to AOCI
Accounting rules allow companies to recognize some "paper" gains as increases in stockholders' equity. It's a way to show profits that the company has made but not yet realized or "locked in." These show up in equity as "accumulated other comprehensive income." Changes in the value of assets because of fluctuations in currency exchange rates get reported in AOCI. So do increases in the market value of certain securities that the company is holding on its books. These and other miscellaneous gains are held in AOCI until the company actually realizes them as profit, in which case they flow to retained earnings.