Position sizing turns a trading idea into a defined financial decision. This guide explains how to calculate how many shares to buy from your account risk, entry price, stop distance, trading costs, gap risk, and portfolio limits—so each trade is sized consistently rather than emotionally.
Overview
Position sizing is the process of deciding how many shares to purchase before entering a trade. The goal is not to maximize the size of every winning position. It is to keep a losing trade within an amount of risk you have already accepted.
A simple position-sizing framework starts with four questions:
- How much of the account may be lost if the trade reaches its planned exit?
- Where is the entry price?
- Where is the invalidation point or stop price?
- Would the resulting position exceed your portfolio or liquidity limits?
The central calculation is:
Number of shares = allowable trade risk ÷ risk per share
Risk per share is usually the difference between the entry price and the stop price. For a long trade, that is entry price − stop price. For a short trade, it is generally stop price − entry price. The result should be rounded down to a whole share unless your broker supports fractional shares and your strategy allows them.
This method does not predict whether a stock will rise or fall. It is a risk-control tool that can be used alongside technical analysis, fundamental research, earnings planning, or signals from an algorithmic system. If you use a trading bot or AI stock trading bot, confirm that its order sizing, stop logic, and maximum exposure settings match your own limits rather than assuming the software will manage risk automatically.
How to estimate
Use the following repeatable process before placing an order.
- Set account risk. Choose a maximum dollar loss for the trade. A beginner may prefer a conservative fixed amount while learning, rather than changing the amount based on confidence.
- Define the entry. Use the actual planned entry, a limit price, or a reasonable estimate if the order has not been submitted. Do not use an idealized price that is unlikely to fill.
- Define the stop or invalidation level. The stop should reflect the price level at which the trade thesis is no longer valid. It should not be selected only to produce a larger share count.
- Calculate risk per share. Subtract the stop price from the entry price for a long position. Add an allowance for commissions, fees, spread, and possible slippage.
- Divide allowable risk by risk per share. This gives the theoretical share quantity.
- Apply portfolio limits. Compare the position's market value with your maximum exposure to one stock, sector, theme, or highly correlated group.
- Round down and verify the order. Check the share quantity, order type, stop instructions, available cash, and margin impact before sending the trade.
A practical stock trading risk calculator can be a spreadsheet with fields for account equity, risk percentage or dollar limit, entry price, stop price, estimated costs, maximum position value, and final share count. Keeping the calculation visible helps separate the sizing decision from the excitement of a fast-moving setup.
For volatile stocks, consider using a wider, technically meaningful stop rather than forcing a tight stop. A volatility-based planning method using ATR can help provide context; see Stock Market Volatility Explained: How to Use VIX and ATR in Trade Planning. Wider stops normally reduce the number of shares when the account-risk limit stays unchanged.
Inputs and assumptions
Account risk
Account risk is the maximum planned loss, not the amount of money you intend to invest. You can express it as a dollar amount or as a percentage of current account equity. If equity changes materially, recalculate the dollar amount instead of treating an old figure as permanent.
For example:
Allowable risk = account equity × selected risk percentage
The appropriate percentage depends on experience, strategy, liquidity, and tolerance for a losing streak. The calculation is useful even when the selected limit is very small.
Entry and stop distance
The stop distance is the main driver of share quantity. A trade with a $1 stop distance can produce twice as many shares as a trade with a $2 distance when the allowable loss is the same. That does not make the first trade safer: the stop may be more vulnerable to normal price movement, gaps, or spread costs.
Costs and execution
Include estimated commissions where applicable, the bid-ask spread, and slippage. Slippage can be especially relevant in premarket movers, after-hours stock movers, thinly traded shares, and rapid news events. A stop order may execute at a less favorable price in a gap or fast market. Therefore, the planned stop loss is a control point, not a guaranteed exit price.
Maximum portfolio exposure
Risk per trade is only one limit. Set a separate maximum position value, such as a percentage of account equity, if a single stock could dominate the portfolio. Also consider existing exposure through ETFs, options, sector funds, or correlated holdings. Two individually acceptable trades can create excessive combined risk when they respond to the same market catalyst.
For broader allocation decisions, compare holdings and concentration alongside fees and structure using How to Compare Stock Market ETFs by Fees, Holdings, and Risk.
Worked examples
Example 1: Basic long trade
Assume an account has a selected maximum trade risk of $100. The planned entry is $50 and the stop is $48.50. Risk per share is $1.50.
Share quantity = $100 ÷ $1.50 = 66.66
Rounding down gives 66 shares. The planned price risk is $99 before trading costs and slippage. The position's approximate market value is $3,300, so it must also fit the trader's maximum position-value limit and available cash.
Example 2: Wider stop, smaller position
Keep the same $100 account-risk limit, but use a $50 entry and a $46 stop because the setup requires more room. Risk per share is now $4.
Share quantity = $100 ÷ $4 = 25 shares
The share count falls from 66 to 25. That is the expected effect of a wider stop when risk remains fixed. Moving the stop closer solely to buy more shares would change the trade's risk profile and may place the stop inside ordinary price noise.
Example 3: Portfolio cap overrides the risk calculation
Suppose the first calculation permits 100 shares at a $20 entry, creating a $2,000 position. If your maximum exposure to one stock is $1,500, the portfolio rule permits only 75 shares. The final quantity is the lower of the risk-based quantity and the exposure-based quantity.
In practice, use this decision rule:
Final position size = the smallest quantity allowed by trade risk, portfolio exposure, available cash, liquidity, and broker restrictions.
When to recalculate
Recalculate before every new trade, and again whenever a material input changes. That includes a different entry price, a revised stop, a change in account equity, unusual volatility, a wider spread, or a new position in the same sector.
Recheck sizing before earnings, major economic releases, or other scheduled catalysts. A planned stop may not protect against an overnight or intraday gap at the exact level. If gap risk is unacceptable, reducing size, avoiding the event, or using a different strategy may be more appropriate than assuming the stop solves the problem. A repeatable framework for event risk is available in the Fed and CPI Trading Guide.
Review your template when your broker changes order features, fees, margin terms, fractional-share rules, or market access. Update estimates when your average trading costs or typical slippage changes. Also revisit the framework after a series of losses, because a drawdown can reduce account equity and may justify temporarily lowering trade risk.
Before submitting an order, use this checklist:
- Is the trade thesis and invalidation level written down?
- Are entry, stop, and estimated costs realistic?
- Does the planned loss fit the account-risk limit?
- Does the position fit single-stock and sector exposure limits?
- Have earnings, macro events, liquidity, and gap risk been checked?
- Is the final share count rounded down and recorded?
Position sizing cannot remove market risk, but it can make that risk explicit before capital is committed. Save the calculation in a spreadsheet or trading journal, update the inputs before each order, and treat the smallest permitted size—or no trade—as a valid decision when the numbers do not fit.