Option payoff and strategy builder
Combine up to four option or stock legs. See profit and loss at expiry and today, the breakevens, and the worst and best case.
How it works
At expiry each option is worth its intrinsic value, so the strategy's P&L is a sum of hockey sticks: straight lines that bend only at the strikes. That makes the breakevens, maximum profit and maximum loss exact: the tool checks every strike and the slope beyond the highest one, and reports "unlimited" when that slope is not flat.
The "today" curve revalues each option with Black-Scholes at the volatility, rate and days to expiry you set, which shows how much time value is left. Use Price legs to fill every premium from the same model.
Assumptions
- All option legs share one expiry date.
- European options; the today curve uses Black-Scholes with one volatility for every strike.
- Quantities are in units of the underlying. Multiply by the contract size (often 100) for real positions.
- Commissions, margin and early assignment are ignored.
Show the codePython, runs in the playground
import numpy as np
# (kind, side, qty, strike, premium); side +1 long, -1 short
legs = [("call", +1, 1, 100, 2.49), ("call", -1, 1, 110, 0.14)]
def pnl(S):
total = 0.0
for kind, side, qty, K, prem in legs:
payoff = np.maximum(S - K, 0) if kind == "call" else np.maximum(K - S, 0)
total = total + side * qty * (payoff - prem)
return total
S = np.linspace(0, 200, 200_001)
P = pnl(S)
cross = np.where(np.diff(np.sign(P)) != 0)[0]
print("Breakeven:", [round(float(S[i]), 2) for i in cross])
print(f"Max profit: {P.max():.2f}")
print(f"Max loss: {P.min():.2f}")
Questions
How are breakevens found?
The expiry payoff is piecewise linear with kinks only at strikes, so the tool solves for zero on each straight segment exactly rather than scanning a grid.
Why is the today curve smoother than the expiry curve?
Before expiry each option still has time value, which rounds off the corners. As days to expiry falls toward zero, the today curve converges to the expiry payoff.
Can I model a covered call?
Yes. Add a long stock leg (its strike field is the entry price) and a short call. The presets include a covered call.
Does it handle different expiries, like a calendar spread?
Not in this version. All legs share one expiry.
Educational use only, not investment advice. Results depend on the model's assumptions listed above and on your inputs. Calculations run in your browser and nothing you enter is sent to a server.