The Sharpe ratio helps investors evaluate the relationship between risk and return for an asset. Since William Sharpe introduced it in the 1960s, the Sharpe ratio has become one of the most widely used metrics in finance and economics. By quantifying both volatility and performance, this tool allows for an incremental understanding of the use of risk to generate a return. With the help of Microsoft Excel, the otherwise intimidating Sharpe ratio formula can be easily utilized.

Here is the standard Sharpe ratio equation:

Sharpe ratio = (Mean portfolio return − Risk-free rate)/Standard deviation of portfolio return,or,

S(x) = (rx - Rf) / StandDev(x)

To recreate this formula in Excel, create a time period column and insert values in ascending sequential order (1, 2, 3, 4, etc.). Each time period is usually representative of either one month or one year. Then, create a second column next to it for returns and plot those values in the same row as their corresponding time period.

In the third column, list the risk-free return value, which is normally the current returns for U.S. Government Treasury bills. There should be the same value in every row in this column.

A fourth column has the equation for excess return, which is the return minus the risk-free return value. Use the cells in the second and third columns in the equation. Copy this equation into each row for all time periods.

Next, calculate the average of the excess return values in a separate cell. In another open cell, use the =STDEV function to find the standard deviation of excess return. Finally, calculate the Sharpe ratio by dividing the average by the standard deviation. Higher ratios are considered better.

Sharpe ratios can also be calculated using Visual Basic for Applications (VBA) functions. However, you should understand how to use a VBA before attempting to provide Excel arguments for calculating the Sharpe ratio.