Offline Black-Scholes Calculator
Download the ZIP once. The extracted index.html file prices European calls and puts in your browser, even when you’re offline.
Standalone HTML in ZIP · 556.6 KB · Version 1.0.0
From ZIP to first calculation
- Extract the ZIP. On Windows, right-click it and choose Extract All. On a Mac, double-click the ZIP.
- Open
index.html. Double-click the file in the extracted folder. You can disconnect before opening it and reopen the same file later. - Run the example. Select Load example, choose Call or Put, then select Calculate.
The one-year example gives about $10.45 per share for the call and $5.57 for the put.
Enter the six pricing inputs
Suppose a stock trades at $100 today and the option has a $100 strike one year from now. Use the entries below for both the call and the put. The form expects plain numbers. In a field labeled (%), enter 20 for 20% volatility and 5 for a 5% rate.
| Offline form field | Enter | Meaning |
|---|---|---|
| Spot price | 100 | Current price per share |
| Strike price | 100 | Exercise price per share |
| Time to expiry (years) | 1 | One year remaining |
| Annual risk-free rate (%) | 5 | 5% continuously compounded rate |
| Annual dividend yield (%) | 0 | No dividends |
| Annualized volatility (%) | 20 | 20% annual volatility |
Compare the offline call and put prices
These prices were calculated in the extracted HTML file with the browser offline. Select Load example to set the strike to $100, the annual risk-free rate to 5%, the dividend yield to 0% and volatility to 20%. For each row, set the spot price and time, choose Call and press Calculate. Switch to Put and press Calculate again.
| Scenario and inputs | Call | Put |
|---|---|---|
| One year (spot $100, time 1 year) | 10.45058357 | 5.57352602 |
| 30 days (spot $100, time 30/365 years) | 2.49337682 | 2.08326120 |
| At expiry (spot $120, time 0 years) | 20.00000000 | 0.00000000 |
For 30 calendar days, enter 0.0821917808219178 in Time to expiry (years). This is 30 divided by 365, written as the decimal the form accepts. At expiry, a $120 share gives the $100 call a value of $20 and the put a value of zero.
Try a put while your browser is offline
Open the extracted index.html and select Load example to restore the sample inputs. Choose Put, leave strike at 100 and set spot to 95 and time to expiry to 0. Select Calculate. The model value should be 5 currency units per underlying unit, and the status should read “Expiry intrinsic value.” You can repeat this check with the network disconnected.
Change only the option type to Call. The previous value clears as soon as you edit the form. Select Calculate again to see 0. With the underlying at 95, exercising the right to buy at 100 has no value.
Move inputs between the browser and a spreadsheet
The offline form takes percentage numbers. For the sample one-year option, type 5 for the rate and 20 for volatility. In the Excel pricing workbook, type 5% and 20% in the corresponding cells. For a shorter option with 73 days left, enter 0.2 years in the offline form. A spreadsheet formula such as =73/365 gives the same time input. Compare the same option type and dividend yield in both tools.
Calculation method
The same pricing engine uses the continuous-yield BSM formula with expiry and zero-volatility branches.
Scope and limitations
The standalone file covers European pricing. For early exercise, inverse IV and scenarios, use the specialist site tools.
