First and foremost the difference between the foreign exchange market and the stock market is that while foreign exchange market is a global market, the stock market is a local one. Secondly, foreign exchange is traded between individuals, governments, banks, institutions, while the stock markets deal with individuals, institutions and banks. Governments do not find a place in the stock markets. Third in stock markets, what is traded is stocks, or shares, which either can be replaced by shares or other stocks. In the case of foreign exchange markets, the only thing that is traded is currency.
The foreign exchange market was introduced in the early 70s of the last decade, when the Bretton Woods Agreement between nations was introduced. Prior to that the value of the foreign currency was based on the stock of gold held by each nation. The Bretton Woods Agreement did away with that, and allowed countries to set their foreign exchange rates, meaning that one dollar would be worth so much of sterling pound and vice versa, on a basis of demand and supply.
When countries trade with each other, through their business or from government to government basis, they either have a surplus of one currency or a deficit in another. They try and make up the surplus to work for them by putting it on sale to other countries which have a shortage of that currency, and where they have a deficit in a particular currency, they buy from a country which has a surplus of that currency. Read this carefully. This is the crux of the matter.
Stock markets generally work on the same principle, but they have fixed hours of trading. In foreign exchange markets, it is taking place all the time, throughout the day and night, 365 days in a year. Obviously, just as in stock market, countries take a hit when their currency depreciates, or their need for a currency is so high, that the other dealing country takes advantage of that high demand in the market, and marks up its surplus currency to a higher level. This trade reflects in some measure the stock market. Demand and supply apply equally.
As countries have liberalised their foreign exchange regimes, except one or two, the market rate of the currency is determined by demand and supply. This is a complex mechanism, and is based on various parameters for which specialist economists and analysts are employed. Normally, an individual is not allowed to trade in the forex market, as in stock markets. But the individual could join an investment banker who is authorised to deal in foreign exchange, and that banker inturn passes on the profit or loss to the individual, depending upon the positions taken.
Stock markets may trade in something like a billion or more dollars per day. In the foreign currency market, the amounts involved are four to nearly 9 times more. And the market varies from day to day.
While stock markets are generally immune to the foreign currency/exchange markets, there is now a closer relationship between the two, owing to globalisation. A sharp dip in the forex market say for dollar ratio with the Canadian dollar would lead to a surge of buying up dollars by Canadians and others, who will later cash in when the dollar regains some of its foothold. In foreign exchange markets, the deals are made even up to the eight or ninth decimal digit, owing to the awesome amounts involved. In stock markets this is not so.
There is a commonality however. Stock markets rise and fall, at least now, in tandem with the forex market. The vice versa is also true. The reason is that the value of the stock in dollar terms has dipped, thus driving down the stock value, and a rise in the dollar value also shows a reflection in stock sales, for those who want to take advantage of the rising dollar value.
Another commonality is that due to globalisation, and freeing up of foreign exchange rules by countries, allowing free float of the currency (meaning let the market decide the value of the currency), leads to people taking long and short positions, in much the same manner as commodity markets or stock markets.
The most obvious and significant difference is that stocks need time to be cashed, but foreign currency markets always deal in cash only! Even this is changing. Maybe in the days to come, there may be a further blurring of the difference between the two.