Lesson 1.4: Costs: spread, fees and slippage
Learn what trading really costs: the spread, taxes and fees, market impact and slippage, and see how a few basis points decide whether a strategy survives.
By the end of this lesson you will be able to list the explicit and implicit costs of a trade, add them up in basis points for a round trip, estimate market impact with the square-root rule, measure the shortfall between a paper trade and the trade you really got, and judge how trading frequency turns a small cost into a large drag. You will find that a round trip costing about 12 basis points turns a signal that earns 15 basis points a trade into 7 per cent a year, that costs 50 per cent higher than assumed turn that profit into a loss of 8 per cent, and that a missed fill can cost more than the price you paid. You should have read Lessons 1.1 and 1.3, which explain the order book and the arithmetic of returns. The mathematics is basis points, percentages and one square root. This course is education about how markets work, not investment advice, and the charges quoted are examples to be checked against current exchange and broker notices.
The most common reason a research result disappears in live trading is cost. A backtest that trades at closing prices for free describes a world that does not exist. Real trading pays brokers, exchanges and governments, crosses spreads, moves prices and arrives late. Many of the most appealing ideas in finance, such as short-term reversal and high-frequency signals, have a gross edge so small that costs decide the result, which is why serious firms treat cost modelling as a core part of research and not an afterthought.
The evidence from ordinary traders is blunt. A study published by SEBI in 2025 looked at individual traders in India's equity derivatives segment and reported that about 91 per cent of them made net losses in the financial year 2024-25, after accounting for transaction costs. Costs are not the only reason, but they ensure that a strategy needs a real edge, not just a hopeful view, to come out ahead.
The costs of a trade
Costs fall into two groups: the ones that appear on a contract note and the ones that do not.
Cost · Kind · What it isBrokerage · Explicit · The broker's fee, often a flat amount per order or a small percentage
Exchange transaction charges · Explicit · A fee to the exchange per rupee of turnover
Taxes on trading · Explicit · In India, the securities transaction tax (STT) and other statutory levies
Spread · Implicit · Buying at the ask and selling at the bid, instead of at the mid-price
Market impact · Implicit · The price moving because of your own order
Timing and delay · Implicit · The price moving between the decision and the fill
Missed fills · Implicit · The gain on shares you wanted and could not get
Financing and borrowing · Both · Interest on margin, the cost of borrowing shares to short
A useful unit for all of them is the basis point, one hundredth of one per cent. Expressing every cost as a fraction of the traded value lets you add them up and compare them with the edge of a strategy, which is also measured in basis points per trade.
Explicit costs in India
The statutory and exchange charges depend on the product, and they change with each budget and each exchange circular, so the figures below are an illustration to be checked against the current rules. At the time of writing, the securities transaction tax was 0.1 per cent of the value on both the buy and sell side of an equity delivery trade, and 0.025 per cent on the sell side of an intraday equity trade. For futures it is charged on the sell side at 0.05 per cent of the traded value, following a change from 1 April 2026, and for options on the sell side at 0.15 per cent of the premium. The exchange transaction charge on the NSE for the cash market is about ₹297 per crore of turnover on each side, with a further ₹10 per crore contributed to a protection fund, and for equity futures about ₹173 per crore, based on an exchange circular of October 2024. On top of these are goods and services tax on brokerage and exchange fees, stamp duty on purchases, a small regulatory turnover fee and, for delivery trades, depository charges. Your broker's contract note lists each one.
In basis points, a worked example for an intraday trade in a cash equity makes the scale clear. The STT on the sale is 2.5 bp. The exchange charge of ₹307 per crore on each side is 0.307 bp each, 0.614 bp for the round trip. A delivery trade pays 10 bp of STT on each side, 20 bp for the round trip, which is why long-term investors, who trade rarely, can bear it and active traders cannot.
A futures example: take a hypothetical index level of 25,000 and a lot of 65, giving a contract value of 25,000 × 65 = ₹16.25 lakh. A round trip, buying and then selling, pays STT of 0.05 per cent on the sale, ₹812.5, an exchange charge of about ₹28 per side, ₹56 together, and, say, a flat brokerage of ₹20 an order, ₹40. The total is ₹909, or 5.6 bp of the contract value, before goods and services tax and other levies. The tax is by far the largest part. Lot sizes, the index level and the rates all change, so the point is the method: convert every charge to basis points of the traded value and add.
Implicit costs
The costs that never appear on a contract note are often larger.
The spread
Lesson 1.1 showed that a market order buys at the ask and sells at the bid. If the quoted spread is 5 bp, a round trip with market orders pays the whole of it: half on the way in, half on the way out. For a highly liquid share the spread may be one tick, 1 or 2 bp, and for a small company's shares 50 bp or more. A strategy that trades small, illiquid shares often, pays the spread many times a year.
Market impact
When you buy, your own order pushes the price up, and when you sell, down. The effect grows with the size of the order compared with normal volume, and it fades afterwards, though not instantly. A widely observed empirical regularity, often called the square-root rule, says that the impact of an order is roughly proportional to the daily volatility of the stock times the square root of the order size as a fraction of the typical daily volume:
impact ≈ Y × σ × √(Q ÷ V)
where σ is the daily volatility, Q the quantity traded, V the daily volume, and Y a coefficient of order one that varies by market and by study. Take a share with a daily volatility of 2 per cent, which is 200 bp. An order of 1 per cent of the daily volume has a square root of 0.1, so with Y = 1 the impact is about 200 × 0.1 = 20 bp. An order of 4 per cent of daily volume has a square root of 0.2 and an impact of 40 bp. The cost grows with the square root of size, not in proportion: quadrupling the order doubles the impact per share, so the total cost rises eightfold. The rule is an approximation, not a law of nature, and the coefficient should be estimated from your own fills.
Timing and missed fills: implementation shortfall
A trade is a decision followed by an execution, and the price moves in between. Implementation shortfall, a measure introduced by the researcher André Perold, is the difference between the return of the idea on paper, as if you had traded the whole size at the decision price, and the return you actually got.
Suppose you decide to buy 10,000 shares at 100.00, the price at the moment of decision. Over the next hours you manage to buy 8,000 at an average of 100.12, and then the price runs away and you give up on the other 2,000. By the end of the day the shares are at 101.00. On paper the idea made 10,000 × 1.00 = ₹10,000. In reality you made 8,000 × (101.00 − 100.12) = ₹7,040. The shortfall is ₹2,960. It has two parts: an execution cost of 8,000 × 0.12 = ₹960 for paying above the decision price, and an opportunity cost of 2,000 × 1.00 = ₹2,000 for the shares you did not get. The second is larger, and it never appears in any fee schedule. A passive limit order saves on the first and risks the second, and a market order does the opposite. This is the central trade-off of execution, and Lesson 5.4 takes it up again.
What costs do to a strategy
Add up a round trip for the intraday cash example, in basis points. Costs are illustrative where noted.
Component · Round trip (bp)Spread, quoted at 5 bp, paid in full · 5.0
Market impact, 1 bp each way (illustrative) · 2.0
STT on the sale · 2.5
Exchange charges · 0.6
Brokerage and other levies (illustrative, 1 bp each way) · 2.0
Total · 12.1
Twelve basis points sounds small. It is not, because it is paid every time. The annual cost is the cost per round trip times the number of round trips a year. At 12.1 bp:
A strategy that trades once a month, 12 round trips, pays 1.45 per cent a year.
One that trades once a fortnight, 26 round trips, pays 3.15 per cent.
One that trades weekly, 52 round trips, pays 6.30 per cent.
One that trades daily, 250 round trips, pays 30.3 per cent a year.
This is why the gross edge of a strategy, the average profit per trade before costs, must be compared with the cost per trade. A strategy with a gross edge of 15 bp per round trip and a cost of 12.1 bp has a net edge of 2.9 bp per trade. Trading daily, that is 2.9 × 250 = 725 bp, or 7.2 per cent a year, against a gross return of 15 × 250 = 3,750 bp, or 37.5 per cent. Costs consume four fifths of the gross return.
Predict first: the same strategy faces costs 50 per cent higher than you assumed, 18.2 bp for the round trip instead of 12.1. The gross return is 37.5 per cent a year. Will the net return fall by about a sixth, by about half, or turn negative? Decide before reading on.
It turns negative. The net edge per trade becomes 15 − 18.2 = −3.2 bp, and over 250 trades the net return is −3.2 × 250 = −800 bp, a loss of 8 per cent a year, despite a gross return of 37.5 per cent. A cost error of 6 bp, less than the price of a small spread, took the strategy from a 7 per cent profit to an 8 per cent loss. When the edge is thin, the answer is dominated by the estimate of cost, and the estimate is usually too low.
Modelling costs in research
Three habits keep costs honest.
1. Put costs in every backtest from the start. A backtest without costs is a draft, not a result. Charge the half-spread on every trade, add fees and taxes at their real rates, and add an impact term that grows with trade size relative to volume.
2. Stress the assumption. Rerun the test with costs 1.5 and 2 times higher. If the strategy dies at 1.5 times, it is too fragile to trade, and you have learned that cheaply.
3. Reduce turnover. Costs scale with trading, so slower signals, wider trading bands, netting of opposite trades across a portfolio, and rebalancing less often all raise the net result. A signal that adds 0.5 bp of gross edge per unit of turnover must be traded sparingly.
A related point is capacity. Impact grows with the square root of the size you trade, so the profit per rupee falls as the strategy grows. A strategy that earns a net 7 per cent on ₹1 crore may earn nothing on ₹100 crore, because the impact of the larger orders eats the edge. Lesson 4.4 returns to capacity, and it is one reason the best small strategies cannot simply be scaled up.
Liquidity providers face the same arithmetic from the other side: a market maker earns the spread but bears the risk of trading against better-informed people, as Lesson 1.1 explained. A limit order saves the spread and impact but risks a missed fill, and the right choice depends on the signal: a fast-decaying signal needs a market order, and a slow one can afford to wait.
python
import numpy as np
def roundtripbp(spreadbp=5.0, impactbpeachway=1.0, feesbp=5.1):
"""Round-trip cost in basis points: spread paid in full, impact on both legs, plus fees and taxes."""
return spreadbp + 2 impactbpeachway + feesbp
def netreturnpct(grossedgebp, tripsperyear, costkwargs):
return (grossedgebp - roundtripbp(costkwargs)) tripsperyear / 100
print(roundtripbp(), round(netreturnpct(15, 250), 2)) # 12.1 bp, about 7.2% a year
print(round(netreturnpct(15, 250, feesbp=5.1 + 6.1), 2)) # costs 50% higher: about -8.0% a year
for trips in (12, 26, 52, 250):
print(trips, round(trips roundtripbp() / 100, 2), "% of capital a year")
def sqrtimpactbp(dailyvolpct, ordershareofvolumepct, y=1.0):
return y dailyvolpct 100 np.sqrt(ordershareofvolumepct / 100)
print([round(sqrtimpactbp(2.0, q), 1) for q in (1, 4)]) # 20 bp and 40 bp
def shortfall(decisionpx, fills, endpx, intendedqty):
"""Implementation shortfall = execution cost on filled shares + opportunity cost on unfilled shares."""
filled = sum(q for , q in fills)
avg = sum(p q for p, q in fills) / filled
paper = intendedqty (endpx - decisionpx)
actual = filled (endpx - avg)
return paper - actual, filled (avg - decisionpx), (intendedqty - filled) (endpx - decisionpx)
print(shortfall(100.0, [(100.12, 8000)], 101.0, 10000)) # (2960, 960, 2000)
a futures round trip in rupees and basis points
value = 25000 65
cost = 0.0005 value + 2 1.73 value / 1e5 + 40
print(round(cost, 1), round(cost / value 1e4, 2), "bp")
Common mistakes
Backtesting at closing prices with no costs. The result describes a market you cannot trade.
Quoting only the brokerage. The spread, impact and taxes are usually larger.
Using one flat cost for every stock. Small, illiquid stocks have wide spreads and large impact.
Forgetting that taxes and fees change. Check the current rates, and keep them as parameters, not constants buried in code.
Ignoring the cost of missed fills. A limit order that does not fill has an opportunity cost.
Trading too often for the edge. Divide the gross edge per trade by the cost per trade before you build anything.
Assuming a strategy scales. Impact grows with size, so profit per rupee falls.
Not stress-testing costs. If a 50 per cent error in costs flips the sign, the result is not robust.
Key takeaways
The costs of trading are explicit, such as brokerage, exchange charges and taxes, and implicit, such as the spread, market impact, delay and missed fills. Express them all in basis points and add them up.
The spread is paid in full on a round trip with market orders. Impact grows roughly with the square root of the order's share of daily volume: about 20 bp for 1 per cent of volume and 40 bp for 4 per cent, in the example.
Implementation shortfall is the paper return minus the real return. In the example, a ₹2,960 shortfall was ₹960 of execution cost and ₹2,000 of missed gain.
A round trip of 12.1 bp costs 1.45 per cent a year at 12 trades, 6.3 per cent at 52 and 30.3 per cent at 250.
A gross edge of 15 bp a trade, daily, gives 7.2 per cent a year at a cost of 12.1 bp and −8 per cent at a cost of 18.2 bp. Thin edges are decided by the cost estimate.
Put costs into every backtest, stress them at 1.5 and 2 times, reduce turnover, and remember that capacity falls as size grows.
Check yourself
1. A round trip costs 8 bp. A strategy trades 100 times a year. What is the yearly cost as a share of capital?
8 × 100 = 800 bp, or 8 per cent a year.
2. A share has a daily volatility of 1.5 per cent and you plan an order of 4 per cent of daily volume. Using the square-root rule with Y = 1, what is the impact?
150 bp × √0.04 = 150 × 0.2 = 30 bp.
3. You decide to sell 5,000 shares at 200.00. You sell 4,000 at an average of 199.90, and the rest is never sold. The price falls to 198.00 by the end of the day. What is the implementation shortfall, and its two parts?
On paper the idea made 5,000 × (200.00 − 198.00) = ₹10,000. In reality, 4,000 × (199.90 − 198.00) = ₹7,600. The shortfall is ₹2,400: an execution cost of 4,000 × 0.10 = ₹400 and an opportunity cost of 1,000 × 2.00 = ₹2,000.
4. A strategy has a gross edge of 6 bp a trade and costs of 4 bp a trade. Costs turn out to be 1.5 times higher. What is the net edge?
Costs become 6 bp, so the net edge is 6 − 6 = 0. The strategy has no edge left.
5. Why does a strategy that earns well on ₹1 crore often earn little on ₹100 crore?
Market impact grows with order size relative to volume, so larger orders pay more per rupee and the edge shrinks.
Try this
Set aside forty-five minutes.
1. Take your broker's contract note, or a published charge schedule, for one equity trade and one futures trade. List every charge and convert each to basis points of the traded value.
2. Find the quoted spread of three securities of different size, and compute the round-trip spread cost of each in basis points.
3. Use the square-root rule to estimate the impact of an order of 1 per cent and 5 per cent of daily volume in a stock you know. Use the impact simulator.
4. Invent a trade with a decision price, partial fills and an end-of-day price, and compute the implementation shortfall and its two parts.
5. For a trading frequency of your choice, compute the yearly cost of your round-trip estimate, and the gross edge needed to break even.
6. Use the edge simulator to find the number of trades a year at which a strategy with a gross edge of 8 bp stops being profitable at your cost estimate.
7. Write a short note: the all-in round-trip cost for one strategy you might trade, the break-even gross edge, and how the answer changes if costs are 50 per cent higher.
A good result is a cost table in basis points for one real trade, a break-even edge for a trading frequency, and a stress test of the cost estimate. That completes Module 1. You can now describe how a trade happens, what is traded, how returns and risk are measured and what trading costs. The next module builds the mathematics and statistics needed to study price data, beginning with probability, expected value and the Kelly idea.
Read more
Trading and Exchanges by Larry Harris explains the costs of trading and the behaviour of spreads. Trades, Quotes and Prices by Bouchaud, Bonart, Donier and Gould covers market impact, including the square-root rule, in depth. For the cost-and-capacity view of strategies, Inside the Black Box by Rishi Narang gives a practitioner's picture. For current taxes, charges and contract specifications, use the NSE and SEBI circulars and your broker's schedule, which change from time to time.
Tags: Quant Trader Transaction costs Slippage Market impact Implementation shortfall