The stock market is an arena where shares of public limited companies are issued, bought and sold. Just like one goes to a cloth market to buy cloth or a fruit market to buy fruit, the stock market is the place to go to buy a stock of a company. A stock is basically bought when either the company issues it or when an investor who already owns it decides to sell his holdings and places them in the market for selling. An investor who wishes to sell his stocks is basically of the opinion that the price of his stock is likely to go down. At that point, an investor who buys the same stock is of the opinion that the price of the stock is likely to go up. Thus the stock market is a place where millions of investors hold opposing views about any particular stock. The price of the stock thus moves in the direction of the majority.
This basic disparity of views creates the dynamics of demand and supply, accumulation and distribution. Many factors contribute to the determination of the price of a stock. Politics, economy, social unrest natural disasters, media, the company itself, the promoters, major institutions, etc. all contribute to determining the price and the demand and supply levels. The collective opinion of all the investors thus creates a sentiment for the stock which is either bearish or bullish. If the basic number of buyers is more than the sellers, the price of the stock is likely to go up and vice versa.
The actual price of a stock is its book value (fair value). If a stock is trading above its fair value, it could be overvalued by the market and probably a good time to sell it. If the stock is trading below the fair value, it could be undervalued and probably a good time to buy the stock. However, other factors need to be considered before making a decision. If the stock is undervalued, there could be a problem with the company or the management and if the stock is overvalued it could be because of some positives like the company’s performance or orders the company has received. But as a basic thumb rule, one may look at the fair price as a mean from which a stock moves and comes back to.