Stock profit calculator

Selling 50 shares bought at $42.10 for $48.75 each, with $9.98 in total trading fees, is a net profit of $322.52 ($2,437.50 in proceeds against a $2,105 purchase cost).

Work out a trade’s gain or loss after transaction fees.

Privacy: runs in your browser

This tool processes your input in this browser. Inputs and results are excluded from analytics. Draft saving is optional and stays on this device; delete saved text with the draft controls. Loading text from a URL is optional and contacts that server; its URL and your IP address are visible to the server. When a button sends your result to another tool, it waits in this tab until that tool opens it, for up to a minute, and is then deleted.

Copy link includes the inputs you choose to share in the address. Anyone with that link can reopen them. Files and generated results are excluded. Password and key tools share settings only.

Example: 50 shares bought at 42.10 and sold at 48.75, with 9.98 in fees. Type your own trade over it.

More options

Net profit or loss

322.52

More results
Step-by-step calculation

Each step uses the numbers you entered. Steps show 12 significant digits; the answer uses full precision.

    Compare with other numbers

    Save the current answer, then change an input to compare. This clears when you leave.

    Rounding and decimal places

    Rounding changes how numbers are shown, not how they are calculated.

    Automatic precision shows money to two decimal places and rounds other answers for reading: up to six significant digits, with whole numbers kept in full. Thousands separators such as 1,000 are accepted; use a dot for decimals.

    More
    Quick calculator

    Use +, −, ×, ÷, parentheses and %. This doesn’t change the tool above.

    Keyboard shortcuts

    Sharing and starting over

    A copied link includes what you entered and your settings, so anyone with it can see them. Leave private text out. Files and results are not included; random draws are made again.

    Start over puts the tool back to its starting values and closes any open file or device. Drafts you saved stay on this device until you delete them.

    How it works

    Net profit = shares × (sale price − purchase price) − combined transaction fees.

    Uses one purchase price and currency. Dividends, splits, foreign exchange and taxes are excluded. This does not choose a tax-lot accounting method.

    Next: Stock average calculator

    Next: Calculate ROI

    Before you rely on the result

    Calculations keep full browser-number precision. Money amounts are displayed to two decimal places; other results use up to 12 significant digits. Very large values may lose precision.

    How the net profit or loss changes with shares sold

    Other inputs keep their starting values: Purchase price per share: 42.1; Sale price per share: 48.75; Total purchase and sale fees: 9.98. Examples only, not recommendations.

    Shares soldNet profit or loss
    25156.27
    50322.52
    100655.02
    Cite this page

    ToolOctopus. “Stock profit calculator.” Updated . https://tooloctopus.com/stock-profit-calculator.

    Add an access date if your instructions require one.

    Citation formatting uses citeproc-js by Frank Bennett and Citation Style Language styles. License and source code.

    Find a tool

    Type a task, a unit pair, a sum or a time zone. ↓ to choose, Enter to open.