The secondary market is a market where the securities such as stocks and bonds can be traded freely between investors after existing stocks (or any other securities) have been issued in the primary market. The primary market is where investors buy directly newly issued securities from the issuer.
Normally, trading stock in the national exchanges, such as the New York Stock Exchange (NYSE), the NASDAQ, the London Stock Exchange (LSE), and the Hong Kong Stock Exchange are secondary markets.
The primary market is a direct interaction between the issuer (company or government) and investors. In the primary market, investors can buy shares directly from the company, while in the secondary market, investors buy and sell securities (stocks and bonds) among themselves by using brokers.
The issuer is initially public offerings to the primary market when the issuer needs money from investors, in return investors receive securities. Once investors purchased these securities of the company through a transaction in the primary market, they can offer those securities for subsequent sale to other investors in the secondary market.
The issuer refers to the company for a newly issued stock (and corporate bond), and the government for a newly issued bond.
To put it simply, buying a new car from a dealer works like the primary market. Buying a used car from a used car market (second hand) works like the stocks and bonds secondary market.