Stocks work by allowing investors to buy shares of ownership in a publicly traded company, and as the company grows and becomes more profitable, the value of those shares can increase. When a company goes public, it issues a certain number of shares that are available for purchase by investors. The price of the stock is determined by the supply and demand for those shares, and the stock price can fluctuate based on a variety of factors, such as the company's financial performance, industry trends, and global economic conditions.