How securities markets work: primary and secondary markets, orders and indices
Shares and bonds are first sold to investors and then traded between them, and the way an order is placed decides the price paid. This lesson explains the primary and secondary markets, the order book, the bid-ask spread and market and limit orders, with a calculator that fills both kinds of order against an invented book. It then compares the Arm Holdings and Reddit IPOs, where the seller was different, and shows how price weighting and market-cap weighting change an index.
- Level
- Beginner
- Reading time
- About 22 minutes
- Know this first
- Bank reconciliation and cash
By the end you will be able to:
- tell the primary market from the secondary market and say who receives the money in each
- read an order book and work out the bid-ask spread and mid price
- compare a market order and a limit order on certainty, price and risk of not trading
- explain why a large market order can fill at a worse average price
- check who sold the shares in an IPO and what the company received
- compare price weighting and market-cap weighting in an index
Where shares and bonds are bought and sold
A security is a tradable financial claim, such as a share in a company or a bond issued by one. Companies and governments create securities to raise money, and investors buy them hoping to be paid back with a return. Securities markets are the places, mostly electronic today, where those claims are first sold and then traded again and again.
This is the first lesson in a module on investments and markets. It covers how a security reaches investors, how a trade actually happens, and why the price you pay can differ from the price on the screen. The next lessons look at what stocks, bonds and funds are and how to measure risk and return. To see how a bond is valued once it exists, read the lesson on bond pricing and yield.
The primary market and the secondary market
The US Securities and Exchange Commission's investor site defines the primary market as the market in which newly issued securities are sold to investors and the issuer receives the proceeds. It defines the secondary market as the market where existing securities are bought and sold.
The difference matters for who gets the money. When a company sells new shares in the primary market, the cash goes to the company. When one investor sells shares to another in the secondary market, the cash goes to the seller, and the company receives nothing, although its share price and its ability to raise money later depend on how the market values it.
A company's first sale of shares to the public is an initial public offering, or IPO. The company works with underwriters, which are investment banks that manage and sell the offering. The SEC's investor bulletin says the offering price is set by a mix of market conditions, analysis and negotiation, and that the offering price may bear little relationship to the price at which the shares then trade. After the offering, the shares trade in the secondary market.
Two IPOs, two different sellers
Not every IPO raises money for the company. Two recent offerings on US exchanges show the contrast. Arm Holdings priced its offering in September 2023 and Reddit priced its in March 2024. In Arm's offering, the shares were sold only by a selling shareholder, a wholly-owned subsidiary of SoftBank Group, so the company was not the seller in the offering. In Reddit's offering, most of the shares were sold by the company and the rest were sold by existing stockholders, from whose sales Reddit received no proceeds. Both releases state the figures in the table.
| Offering as announced | Arm Holdings | |
|---|---|---|
| Priced | 13 September 2023 | 20 March 2024 |
| Exchange and symbol | Nasdaq, ARM | NYSE, RDDT |
| Price | $51.00 per ADS | $34.00 per share |
| Securities in the base offering | 95,500,000 ADSs | 22,000,000 shares |
| Value of the base offering, $ million | 4,870.5 | 748.0 |
| Sold by the company | None | 15,276,527 shares |
| Sold by shareholders | 95,500,000 ADSs | 6,723,473 shares |
| Underwriters' option, 30 days | 7,000,000 ADSs | 3,300,000 shares |
At $51.00 an ADS, Arm's base offering of 95,500,000 ADSs was worth $4,870.5 million, all of it sold by the selling shareholder rather than by Arm. At $34.00 a share, the 69.4% of Reddit's offering sold by the company came to $519.4 million before underwriting discounts and commissions. The table shows why "the company went public" does not always mean "the company raised money". Both releases also describe an option for the underwriters to buy additional shares at the offering price within 30 days.
Neither release says how the shares then traded, and this lesson does not use first-day prices. The point is the structure: who sells, at what price, and where the shares then trade.
Exchanges, market makers and the order book
Arm chose the Nasdaq Global Select Market and Reddit the New York Stock Exchange. An exchange is a marketplace that brings buyers' and sellers' orders together under published rules. Once the shares are listed, anyone with a brokerage account can send an order to buy or sell through a broker.
An exchange collects the orders in an order book. Buyers' offers are bids, and the best bid is the highest price any buyer will currently pay. Sellers' offers are asks, and the best ask is the lowest price any seller will currently take. The best ask is always above the best bid, otherwise the two orders would trade. The gap between them is the bid-ask spread, and the point halfway between them is the mid price.
The SEC's glossary defines a market maker as a firm that stands ready to buy or sell a stock at publicly quoted prices. Because market makers quote prices at which they will both buy and sell, a buyer can usually find a seller. The spread is, in a simple view, the price of that convenience, and it is paid by whoever wants to trade right now. The SEC defines liquidity as how easily or quickly a security can be bought or sold in a secondary market. A stock with many orders close to the mid price has a small spread and is called liquid.
Market orders and limit orders
There are two basic ways to ask a broker to trade. The SEC's investor site describes a market order as an order to buy or sell immediately. It guarantees that the order will be executed but does not guarantee the price, and a market order generally executes at or near the current bid for a sale or the ask for a purchase. It adds that the last-traded price is not necessarily the price at which a market order will be executed.
A limit order is an order to buy or sell at a specific price or better. A buy limit order fills only at the limit price or lower. The trade-off is the reverse of the market order: the price is protected, but the order may never fill, or may fill only in part.
Below, a fictional stock has the order book shown in the table. The prices are invented, and the real market has many more levels, but the mechanics are the same.
| Level | Bid price | Bid shares | Ask price | Ask shares |
|---|---|---|---|---|
| Best | $100.00 | 400 | $100.10 | 300 |
| Second | $99.90 | 600 | $100.20 | 500 |
| Third | $99.70 | 1,000 | $100.40 | 800 |
Buy at the market, or name your price
Set how many shares you want to buy and the limit price for a second, limit order. The left page sends a market order, which takes the cheapest shares on offer until the order is full. The right page sends a limit order, which takes only shares offered at the limit price or lower and leaves the rest waiting in the book. At the starting settings both orders ask for 600 shares, and the limit is $100.15. The best bid is $100.00, the best ask is $100.10, so the spread is $0.10 and the mid price is $100.05.
A market order for 600 shares fills at once at an average of $100.15, $0.05 above the best ask of $100.10, for a total of $60,090. A limit order at $100.15 buys 300 shares now at an average of $100.10 and leaves 300 waiting. The waiting shares become the best bid at $100.15 and fill only if a seller comes down to that price.
Four experiments. First, at the starting settings the market order buys all 600 shares for $60,090, at an average of $100.15, which is $0.05 above the best ask. The limit order buys only the 300 shares offered at $100.10 and leaves 300 waiting, because the next shares are offered at $100.20. Second, cut the order to 300 shares. The market order now pays exactly the best ask of $100.10, because the first level is large enough. Third, set 1,600 shares and watch the average rise as the order eats through every level. Bigger orders move the price against the buyer. Fourth, set the limit to $99.80 and see that the limit order buys nothing and sits below the best bid. It protects the price completely and may never trade.
The same two orders, at the starting settings:
| 600 shares, limit $100.15 | Market order | Limit order |
|---|---|---|
| Shares bought now | 600 | 300 |
| Average price | $100.15 | $100.10 |
| Total cost | $60,090 | $30,030 |
| Shares left waiting | 0 | 300 |
| Trade certain? | Yes | No |
| Price protected? | No | Yes |
Market indices
News reports quote indices such as the S&P 500 or the Dow Jones Industrial Average. The SEC's glossary defines a market index as a measurement of the performance of a specific basket of stocks. How the basket is weighted decides which companies move it. S&P Dow Jones Indices notes that most equity indices are market-cap weighted and float adjusted, so each stock's weight is proportional to its float-adjusted market value. Some indices are instead price-weighted, where weights are set solely by the constituent stocks' prices, and the Dow Jones Industrial Average is its example. Float adjustment counts only the shares that are available to the public.
The two methods can give very different answers. Take two invented stocks. Company A trades at $200 and has 10 million shares, so its market value is $2,000 million. Company B trades at $50 and has 400 million shares, so its market value is $20,000 million. Float adjustment is ignored here for simplicity.
| Two invented stocks | Company A | Company B |
|---|---|---|
| Share price | $200 | $50 |
| Shares in issue, million | 10 | 400 |
| Market value, $ million | 2,000 | 20,000 |
| Weight if price-weighted | 80.0% | 20.0% |
| Weight if market-cap weighted | 9.1% | 90.9% |
Under price weighting, the expensive-per-share Company A makes up 80.0% of the index even though it is a tenth the size of Company B. Under market-cap weighting, Company A is 9.1% and Company B 90.9%. A 1% move in Company B moves a market-cap index about ten times as much as a 1% move in Company A.
What this lesson simplifies
- The book is invented. A real order book has many more levels, changes within milliseconds, and also contains hidden and special order types.
- One buyer, no reaction. In the calculator nobody else trades while the order fills. In practice the book moves as orders arrive.
- Fees are left out. Brokers' commissions, exchange fees and taxes are not part of the calculator.
- Many venues exist. A stock can trade on several exchanges and other venues, so the best prices are not always in one book.
- Only buy orders are shown. A sell order works the same way against the bids.
- The IPO table is structure, not performance. It says who sold shares and at what price, not whether the shares were a good investment.
Common mistakes
Treating the last price as the price you will pay
The last trade is history. A market order pays the asks available now, and a large order can pay more than the best ask.
Using a market order on a thinly traded stock
When the book is thin and the spread is wide, a market order can fill far from the price you saw. A limit order controls the price.
Expecting a limit order to always fill
A limit order trades only if the market reaches your price. A cheap limit may never fill while the price moves away.
Assuming an IPO raises money for the company
It can, but a share sale by existing holders does not. Read who is selling.
Confusing the index with the economy
An index is a basket with a weighting rule. A price-weighted and a market-cap-weighted index of the same stocks can move differently.
Try it yourself
1. A stock has a best bid of $24.80 and a best ask of $25.00. What are the spread, the mid price, and the spread as a percentage of the mid price?
Show the working
Spread = 25.00 − 24.80 = $0.20. Mid price = (24.80 + 25.00) ÷ 2 = $24.90. Spread as a percentage = 0.20 ÷ 24.90 = 0.80%.
2. In the lesson's order book, what does a market order to buy 500 shares cost in total, and at what average price?
Show the working
300 shares at $100.10 = $30,030, then 200 shares at $100.20 = $20,040. Total = $50,070. Average = 50,070 ÷ 500 = $100.14.
3. In the same book, a limit order to buy 500 shares at $100.15 is placed. How many shares are bought, at what cost, and how many wait?
Show the working
Only the 300 shares offered at $100.10 are at or below the limit, costing $30,030. The shares at $100.20 are above the limit. So 300 are bought and 200 wait in the book.
4. Reddit's IPO included 15,276,527 shares sold by the company at $34 each. How much did that raise before underwriting discounts and commissions?
Show the working
15,276,527 × 34 = $519,401,918, which is about $519.4 million. The other 6,723,473 shares were sold by selling stockholders, and Reddit received no proceeds from those.
5. You must buy a stock today and care more about getting it than about a few cents of price. Which order type fits, and what is the risk?
Show the working
A market order, because it is designed to execute immediately. The risk is that the price is not guaranteed, and in a thin book a large order can fill well above the best ask.
Where this is used
- An individual investor chooses between a market order and a limit order when buying through a broker.
- A fund manager splits a large order into pieces to avoid pushing the price against the fund.
- An analyst reads an IPO prospectus to see how much of the offering is new money for the company.
- A saver reads an index fact sheet to see whether the index is weighted by price or by market value.
Key terms
- Primary market
- The market where newly issued securities are sold and the issuer receives the proceeds.
- Secondary market
- The market where existing securities are bought and sold between investors.
- Initial public offering
- The first sale of a company's shares to the public.
- Underwriter
- An investment bank that manages and sells an offering for the issuer.
- Order book
- The list of buy and sell orders waiting at different prices.
- Bid and ask
- The highest price a buyer will pay and the lowest price a seller will take.
- Bid-ask spread
- The gap between the best ask and the best bid.
- Market maker
- A firm that stands ready to buy or sell a stock at publicly quoted prices.
- Market order
- An order to trade immediately at the best available prices.
- Limit order
- An order to trade at a specific price or better.
- Market index
- A measure of the performance of a basket of stocks.
Questions people ask
Why is there a spread at all?
Buyers want to pay less and sellers want to receive more, so their orders sit at different prices. The spread is the gap that has to be crossed for a trade to happen right now.
What does the company get when its shares trade?
Nothing directly. The company receives money only when it sells new shares itself, such as in an IPO or a later share issue.
Is a limit order always safer?
It protects the price, not the outcome. If the market moves away, the order may never fill and you may miss the move you wanted.
Is a price-weighted index worse?
It is a different rule. It is simple, but a company's weight depends on its share price rather than its size, so most broad modern indices weight by market value.
Sources and review
- US Securities and Exchange Commission, Investor.gov, Primary market, Secondary market and the glossary, for the definitions of the primary and secondary markets, market maker, liquidity, initial public offering and market index.
- US Securities and Exchange Commission, Investor.gov, Types of orders, for market orders, limit orders, and the points that a market order guarantees execution but not price.
- US Securities and Exchange Commission, Investor.gov, Updated investor bulletin: investing in an IPO, for what an IPO is, the role of underwriters and how the offering price is set.
- S&P Dow Jones Indices, Getting up to speed with the essentials of index construction, for market-cap weighting, float adjustment and price weighting.
- Arm Holdings plc, Arm announces pricing of initial public offering, 13 September 2023, for the price per ADS, the number of ADSs, the selling shareholder, the Nasdaq listing and the underwriters' option.
- Reddit, Inc., Reddit announces pricing of initial public offering, 20 March 2024, for the price per share, the shares sold by the company and by selling stockholders, the NYSE listing and the underwriters' option.
How the numbers were checked: every cost, average price and weight was recomputed in plain code, and the calculator, which runs separately, was compared with that code across a grid of order sizes and limit prices. The IPO figures come from the two releases cited above. The stock, order book and companies in the index example are invented for teaching.