Sharpe Ratio Calculator · Risk-Adjusted Return

Sharpe Ratio Calculator

Measure risk-adjusted return · How much excess return you earn per unit of risk.

Currency
Setup
% / yr
Sharpe Ratio = (Portfolio Return − Risk-Free Rate) ÷ Standard Deviation. Enter your historical returns below — the calculator will compute the mean, standard deviation, and annualized Sharpe.
Historical Returns
# Return (%)
Enter each period's return as a percentage (e.g. 2.5 for +2.5%, −1.3 for −1.3%). Add at least 3–5 periods for a meaningful Sharpe Ratio.
Sharpe Ratio Result
📊 Analysis Ready
Sharpe Ratio: —
—
📈 Sharpe Ratio
—
💹 Annual Return
—
📉 Annual Volatility
—
🎯 Excess Return
—
Avg Period Return
—
Period Std Dev
—
Periods Analyzed
—
Positive Periods
—
Portfolio Return vs. Risk-Free Rate (Annualized)
Best period —
Worst period —
Range (max − min) —
Downside deviation —
Return / Risk ratio (vs risk-free) —
💡 Interpretation
Enter your returns to see the Sharpe Ratio analysis.
Return Series
#ReturnDeviation from MeanSquared Deviation

Powered by Toolraxy

`; embedCodeTextarea.value = ``; }window.toggleEmbedPanel = function() { if (embedPanel.style.display === 'none' || embedPanel.style.display === '') { generateEmbedCode(); embedPanel.style.display = 'block'; } else { embedPanel.style.display = 'none'; } };window.copyEmbedCode = function() { embedCodeTextarea.select(); navigator.clipboard?.writeText(embedCodeTextarea.value).then(() => alert('Embed code copied!')).catch(() => alert('Press Ctrl+C')); };document.addEventListener('DOMContentLoaded', function() { populateCurrency();currencySelect.addEventListener('change', function(e) { const found = currencies.find(c => c.code === e.target.value); if (found) currentCurrency = found; updateCurrencySymbols(); calculate(); });[riskFreeRate, returnPeriod].forEach(el => { if (el) { el.addEventListener('input', calculate); el.addEventListener('change', calculate); } });renderReturns(); calculate(); }); })();

Creator & Maintainer

Image of Faiq Ur Rahman, CEO & Founder Toolraxy

Faiq Ur Rahman

Founder & CEO, Toolraxy

Faiq Ur Rahman is a web designer, digital product developer, and founder of Toolraxy, a growing platform of web-based calculators and utility tools. He specializes in building structured, user-friendly tools focused on health, finance, productivity, and everyday problem-solving.

Share:

Rate this Tool

User Ratings:

0
0 out of 5 stars (based on 0 reviews)
Excellent
Very good
Average
Poor
Terrible

ADVERTISEMENT

ADVERTISEMENT

Introduction

Two funds can deliver the same annual return while one does it smoothly and the other swings violently along the way. The Sharpe ratio exists to separate those cases. By dividing excess return by volatility, it answers a question raw performance numbers can’t: how much return are you getting for each unit of risk you’re accepting? This calculator is for investors reviewing a portfolio, comparing two funds with different volatility profiles, or stress-testing a strategy before committing capital. You enter the period returns you already have, from a brokerage statement, a fund factsheet, or a spreadsheet and the tool handles the statistics. Everything runs in your browser, nothing is uploaded, and the tool stays free with no sign-up required.

 

How to Use the Sharpe Ratio Calculator

  1. Set the risk-free rate, the annual yield on a short-term government instrument works well as a proxy.

  2. Choose whether the returns you’ll enter are monthly, quarterly, or yearly.

  3. Type each period’s return into the numbered field, expressed as a percentage. Use a minus sign for losses.

  4. Add more periods by clicking “Add another period” and remove any by clicking the X beside the row.

  5. Keep at least three entries, the tool refuses to compute a meaningful Sharpe below that threshold.

  6. Or press a quick-example button,  S&P 500, bond fund, excellent fund, poor performer, high volatility, or steady growth to load a realistic dataset.

  7. Read the Sharpe figure at the top of the results, then check annualized return, annualized volatility, and excess return in the cards below.

  8. Scroll to the returns table to inspect each period’s deviation from the mean and its squared deviation.

 

How the Sharpe Ratio Calculator Formula Works

The Sharpe ratio divides excess return by the standard deviation of returns. This calculator computes it from the raw period data you supply.

Formula: Sharpe Ratio = (Annualized Return − Risk-Free Rate) ÷ Annualized Volatility

Formula: Annualized Return = Mean Period Return × Periods Per Year

Formula: Annualized Volatility = Sample Std Dev × √(Periods Per Year)

Formula: Sample Std Dev = √[ Σ(return − mean)² ÷ (n − 1) ]

Where n is the number of periods entered, and periods per year is 12 for monthly, 4 for quarterly, or 1 for yearly.

The annualization step is what makes data of different frequencies comparable. Monthly returns are multiplied by twelve to produce an annual figure, and monthly volatility is multiplied by the square root of twelve, not by twelve because volatility scales with the square root of time under the standard assumption of independent returns.

Sample standard deviation, using n − 1 in the denominator, is applied rather than population standard deviation. That’s the appropriate choice when your returns are a sample of a longer history rather than the complete population of every return the portfolio will ever produce.

Two edge cases are handled explicitly. If fewer than two periods are entered, the tool stops and asks for more data. If you try to remove returns until fewer than three remain, the tool resets the list to three zeros rather than letting the list collapse. A volatility of exactly zero produces a Sharpe of zero rather than an infinity error.

 

Worked Example

Suppose you have four quarterly returns from a balanced portfolio: +2.4%, −1.1%, +3.8%, and −0.7%. The risk-free rate is 4.5% annually, and you’ve selected quarterly as the return period.

Step 1 – Mean period return:
(2.4 − 1.1 + 3.8 − 0.7) ÷ 4 = 4.4 ÷ 4 = 1.10%

Step 2 – Sample standard deviation:
Deviations from mean: +1.30, −2.20, +2.70, −1.80
Squared deviations: 1.69, 4.84, 7.29, 3.24 → sum = 17.06
Variance = 17.06 ÷ (4 − 1) = 5.687
Std dev = √5.687 ≈ 2.385%

Step 3 – Annualize:
Annual return = 1.10 × 4 = 4.40%
Annual volatility = 2.385 × √4 = 2.385 × 2 = 4.77%

Step 4 – Sharpe ratio:
Excess return = 4.40 − 4.50 = −0.10%
Sharpe = −0.10 ÷ 4.77 ≈ −0.02

The result is a slightly negative Sharpe. The portfolio returned 4.40% annually with relatively low volatility of 4.77%, but it didn’t quite beat the 4.5% risk-free rate. In other words, over this four-quarter sample, a Treasury position would have produced a similar outcome with less risk. Note the small sample: four quarters is short, and the Sharpe ratio will move meaningfully with more data.

Frequently Asked Questions

What does the Sharpe ratio actually measure?

It measures the return an investment earns above the risk-free rate, divided by the volatility of its returns. A higher figure means more excess return per unit of risk. It’s a standard tool for comparing portfolios that have different return and volatility characteristics.

 

Why divide by standard deviation rather than use raw returns?

Because raw returns ignore risk. Two portfolios can average the same annual return while one swings wildly and the other doesn’t. Dividing by standard deviation normalizes the comparison so that smoother return paths are rewarded, which is what most investors actually want.

 

What counts as a good Sharpe ratio?

Below 1.0 is generally sub-optimal. Between 1.0 and 2.0 is good. Between 2.0 and 3.0 is excellent. Above 3.0 is outstanding but often indicates a short or fortunate sample. A negative figure means the portfolio underperformed the risk-free rate.

 

Can a Sharpe ratio be negative?

Yes. If the portfolio’s annualized return falls below the risk-free rate, the excess return is negative and so is the Sharpe ratio. This means the risk taken didn’t earn a premium over a safer alternative.

 

Does the calculator use population or sample standard deviation?

Sample standard deviation, with n − 1 in the denominator. That’s the correct choice when your returns represent a sample of a longer history rather than the complete set of outcomes the portfolio could produce.

 

How many periods of returns do I need?

At least three, which is the tool’s minimum. In practice, twelve monthly returns is a bare minimum for a meaningful figure, and thirty-six or more is considerably better. Short samples produce unstable Sharpe ratios that can shift dramatically with one more data point.

 

Why does my Sharpe ratio change so much when I add a few more months?

Because standard deviation is sensitive to outliers, and a small sample is easily dominated by one or two extreme periods. As the sample grows, individual periods carry less weight and the ratio stabilizes, provided the underlying strategy hasn’t changed.

 

Can I use this for a single stock rather than a portfolio?

Yes. The math is identical, enter the stock’s period returns and a risk-free rate. Just be aware that single stocks have idiosyncratic volatility that a portfolio dilutes, so their Sharpe ratios tend to be lower and noisier.

 

What’s the difference between the Sharpe ratio and the Sortino ratio?

The Sortino ratio uses downside deviation, only negative returns contribute to the risk measure rather than total standard deviation. That makes it more appropriate for strategies with asymmetric return distributions, where upside volatility isn’t something investors want penalized.

 

How do I annualize monthly returns for the Sharpe ratio?

Multiply the mean monthly return by twelve to annualize the return, and multiply the monthly standard deviation by the square root of twelve to annualize the volatility. This calculator performs both steps automatically once you select the monthly return period.

 

Does the Sharpe ratio account for fees and taxes?

Not directly. The returns you enter should already reflect any fees that reduce the portfolio’s value, but the calculator doesn’t apply fee deductions itself. Taxes are typically excluded from Sharpe ratio calculations as well.

 

What if my portfolio’s volatility is zero?

If every period return is identical, the standard deviation is zero. The calculator treats a zero-volatility portfolio as producing a Sharpe ratio of zero rather than an infinite value, since a genuinely riskless return above the risk-free rate would be an arbitrage rather than a portfolio characteristic.

Financial Disclaimer

This Sharpe ratio calculator is an educational tool and does not constitute investment advice. The Sharpe ratio assumes returns are normally distributed, which is not always true in practice, and it penalizes upside volatility identically to downside volatility. Results depend heavily on the sample period, sample size, and the risk-free rate chosen. Historical risk-adjusted performance does not predict future results. Consult a licensed financial advisor before making investment decisions.

ADVERTISEMENT

ADVERTISEMENT