To add standard deviation bars to a bar chart in Excel, you first calculate the standard deviation for each data series, then use Excel's “Error Bars” feature to display them. This works in Excel 2016, 2019, 2021, and Microsoft 365 on Windows and Mac, though the exact menu labels can differ slightly by version and device. The steps below cover both the calculation and the chart formatting.

What You'll Need

  • A set of data with at least two columns: one for categories (e.g., months, product names) and one for values (e.g., sales, test scores).
  • If you have multiple groups (e.g., different years), you'll need a column for each group's values.
  • Excel installed on your computer (desktop version recommended; the web version has limited error bar options).
  • Basic familiarity with selecting cells and using formulas.

Step-by-Step

  1. Prepare your data. Arrange your data in columns. For example, put categories in column A (A2:A10) and values in column B (B2:B10). If you have multiple series, put each series in its own column (C, D, etc.).
  2. Calculate the standard deviation. In a new cell (e.g., D2 for the first series), enter the formula =STDEV.S(B2:B10) for a sample, or =STDEV.P(B2:B10) if your data represents the entire population. Press Enter. Repeat for each series if you have more than one. Note: STDEV.S is the default for most scientific and business use; STDEV.P is for when you have all possible data points.
  3. Create the bar chart. Select your data range (including category labels and values, but not the standard deviation cells). Go to the Insert tab, click the Bar Chart icon (in the Charts group), and choose the first option under “2-D Bar” (usually “Clustered Bar”). Excel will insert the chart on your sheet.
  4. Select the chart and open the error bar options. Click on the chart to select it. You should see a “Chart Design” or “Chart Tools” tab appear in the ribbon. Look for “Add Chart Element” (in the Chart Layouts group). Click it, then hover over “Error Bars”. In the submenu, choose “More Error Bars Options…”. (On older Excel versions, right-click on the chart, select “Select Data”, then click “Error Bars” – but the modern method is via the ribbon.)
  5. Choose the error bar direction and style. The “Format Error Bars” pane will open on the right side. Under “Direction”, select “Plus” if you want only the upper bar (common for showing variability above the mean), “Minus” for lower, or “Both” for a symmetric range. For standard deviation, “Both” is typical. Under “End Style”, choose “Cap” to add small horizontal lines at the ends, or “No Cap” for plain bars.
  6. Specify the error amount. In the same pane, under “Error Amount”, select “Custom”. Click the “Specify Value” button (a small icon with a red arrow). A dialog box appears. In the “Positive Error Value” field, enter the cell reference for your standard deviation (e.g., =Sheet1!$D$2). If you want the same for negative, enter the same cell in the “Negative Error Value” field, or leave it blank if you chose “Plus” direction. Click OK.
  7. Repeat for other series. If you have multiple bars (e.g., two series), the error bars will only apply to the first series initially. To add error bars to the second series, click on the second series in the chart (the second set of bars) to select it, then repeat steps 4–6, referencing the second series' standard deviation cell. You may need to use the “Add Chart Element” > “Error Bars” > “More Error Bars Options” again, but now it will apply to the selected series.
  8. Format the error bars. To change the color, width, or line style of the error bars, click on any error bar to select them, then in the “Format Error Bars” pane, go to the “Fill & Line” tab (paint bucket icon). Adjust the color, transparency, width, and dash type as desired. For example, set width to 1.5 pt and color to black for better visibility.
  9. Add a legend and labels. If you have multiple series, ensure the legend is visible (Chart Design > Add Chart Element > Legend). To add data labels (the actual values on top of bars), right-click on a bar, select “Add Data Labels”. You can then format them to show value or percentage.
  10. Adjust the chart title and axis. Click on the chart title to edit it. For axis labels, click on the axis, then use the “Format Axis” pane to adjust number formats, or add axis titles via “Add Chart Element” > “Axis Titles”.

Common Mistakes

  • Using the wrong standard deviation function. STDEV.S vs STDEV.P – using the wrong one can give misleading error bars. Use STDEV.S for samples (most common), STDEV.P only if you have the entire population.
  • Selecting the standard deviation cells as part of the chart data. If you include the SD cells in the initial chart data range, Excel will plot them as an extra series, not as error bars. Always select only the category and value columns.
  • Forgetting to specify custom values. If you don't choose “Custom” and instead leave the default “Fixed value” or “Percentage”, the error bars will be based on a constant, not your calculated SD.
  • Error bars only on one series. When you have multiple series, you must add error bars to each series individually. Many users think one step covers all.
  • Using “Both” when you only want “Plus”. If your data is non-negative and you want to show only upward variability, “Plus” is more appropriate. “Both” can make bars look symmetrical even when the distribution is skewed.

Tips

  • Use a separate helper column for SD. Keep your SD values in a separate area of the sheet (e.g., column D) so they don't accidentally get included in chart data.
  • Format error bars consistently. Use the same color and width for all series to avoid confusion. A contrasting color (like red on blue bars) helps readability.
  • Consider using “Both” with caps. For most scientific charts, “Both” with caps is the standard. It clearly shows the range of uncertainty.
  • Label your error bars. Add a note in the chart or caption explaining that error bars represent ±1 standard deviation. This is essential for clarity.
  • Update SD automatically. If your data changes, the SD formula will recalculate, but you must manually update the error bar custom values if you used a static number. To avoid this, reference the SD cell directly (e.g., =$D$2) so it updates automatically.
  • Use a bar chart with error bars for comparing means. This is a classic way to show variability across groups. For paired data, consider a line chart with error bars instead.

Troubleshooting

If the error bars do not appear or look wrong, try these steps in order:

  1. Check your selection. Make sure you selected the correct series before adding error bars. Click on the specific bar you want to modify; the “Format Error Bars” pane should show the series name at the top.
  2. Verify the custom value reference. Go back to the error bar options and click “Specify Value”. Ensure the cell reference is correct and the cell contains a number (not text). If the cell is empty or has an error, the bars won't show.
  3. Restart Excel. Sometimes the error bar pane gets stuck. Close and reopen Excel, then try again.
  4. Check for hidden rows/columns. If your data has hidden rows, the STDEV formula might ignore them, but the chart might include them. Unhide all data before creating the chart.
  5. Ensure you're not in “Edit” mode. If you're still editing a formula (the cell shows “Enter” in the bottom left), error bar options may be greyed out. Press Enter to finish editing.
  6. Try the “Add Chart Element” route again. On some versions, the right-click context menu doesn't have “Error Bars”. Use the ribbon method: Chart Design > Add Chart Element > Error Bars > More Error Bars Options.

Frequently Asked Questions

How do I add standard deviation bars to only one bar in a chart?

You can't easily add error bars to a single bar; error bars apply to the whole series. To show SD for only one category, you'd need to split that category into its own series or use a separate chart.

Can I use standard error instead of standard deviation?

Yes. Standard error (SE) is the standard deviation divided by the square root of the sample size (n). Calculate SE in a cell (e.g., =STDEV.S(B2:B10)/SQRT(COUNT(B2:B10))) and use that as the custom error value. The steps are identical.

Why do my error bars disappear when I change the data?

If you referenced a static number instead of a cell, the error bars won't update. Also, if the data range changes (e.g., you add rows), the chart may not include them. Re-select the data and re-specify the error bar values.

What does “Fixed value” error bar mean?

It means you specify a constant number (e.g., 5) for the error bar length. This is useful when you have a known measurement error, but for standard deviation you should use “Custom” with your calculated SD.

How do I remove error bars?

Click on the error bars to select them, then press the Delete key. Alternatively, go to Chart Design > Add Chart Element > Error Bars > None.

Can I add error bars to a 3-D bar chart?

No, Excel does not support error bars on 3-D charts. Use a 2-D bar chart instead.