Standard Deviation Calculator

Paste a data set to calculate sample or population standard deviation, variance, mean, quartiles, z-scores, and the full calculation steps.

Example values loaded Replace the example data with your own values for your calculation.

Calculator is for informational purposes only. Terms and Conditions

\[ s=\sqrt{\frac{\sum_{i=1}^{n}(x_i-\bar{x})^2}{n-1}} \]

Use sample mode when the entered observations are a subset used to estimate a larger population; use population mode when they are the entire group of interest.

1

Choose sample or population

This choice changes the denominator in the variance and standard deviation formulas.

Standard deviation type

Sample: part of a larger group. Population: every member of the group you care about.

Intermediate calculations keep full precision; this setting changes display rounding only.

2

Enter your data

Paste values from a spreadsheet or type them directly. Results update automatically.

Separate values with commas, spaces, tabs, semicolons, or line breaks. Frequency shorthand is supported: 10:3 means the value 10 appears three times.

Example: 2, 4, 4, 4, 5, 5, 7, 9. Scientific notation such as 1.2e3 is accepted. Do not use commas as thousands separators.

Quick examples:
Advanced Options

Only affects the value table and visual; calculations are unchanged.

Flags potential outliers using Tukey’s 1.5 × IQR fences; it does not prove a value is erroneous.

3

Result

Standard deviation is shown first, followed by variance and descriptive statistics.

Sample Standard Deviation
2.1381
data units
8 observations · sample denominator n − 1 = 7
The data values typically vary by about 2.1381 data units around the mean of 5.

Result details

    Show calculation steps Review the mean, deviations, variance, standard deviation, and checks
    1. Enter valid data to see the complete calculation.
    4

    Data Spread Around the Mean

    Each point is an observation. The center line marks the mean; adjacent reference lines mark one standard deviation below and above the mean.

    5

    Method, Sources, and Assumptions

    Calculation basis, statistical conventions, limitations, and authoritative references.

    Descriptive statistics
    Sample: n − 1 Population: N Stable centered calculation

    Standard deviation is the square root of variance. Sample standard deviation uses n − 1 in the denominator; population standard deviation uses N. The calculator computes deviations from the mean directly and does not assume the data are normally distributed.

    • Sample mode requires at least two observations; population mode permits one observation, for which the population standard deviation is zero.
    • Quartiles use the median-of-halves convention used by this calculator; other software may use a different quartile interpolation convention.
    • The 1.5 × IQR rule identifies potential outliers only; it does not determine whether a value is erroneous or should be removed.
    • The mean ± 1 SD visual is descriptive. Standard deviation does not imply that the data follow a normal distribution.

    Calculator guide

    Understanding Your Standard Deviation Result

    The calculator above measures how widely your data values are spread around their mean. Enter one numeric dataset, choose whether it represents a sample or the full population of interest, and the primary result is standard deviation in the same units as your data. The calculator also reports variance, mean, count, quartiles, range, IQR, z-scores, and an optional IQR outlier screen. Standard deviation is always zero or positive: zero means every observation is identical, while a larger value means greater spread on that dataset’s scale.

    Standard deviation is useful because it converts many individual deviations from the mean into one summary of variability. NIST describes standard deviation as the square root of variance and notes that it restores the measure of spread to the original data units, whereas variance uses squared units. NIST’s Measures of Scale provides the statistical basis for that interpretation.

    Input
    A numeric dataset, including decimals, negative values, scientific notation, or value:frequency shorthand.
    Primary output
    Sample standard deviation \(s\) or population standard deviation \(\sigma\).
    Key decision
    Use sample mode for a sample used to represent a larger population; use population mode for the complete population you intend to describe.

    Sample vs. Population Standard Deviation

    The calculation changes only in the variance denominator, but that choice matters most for small datasets. In sample mode, the calculator divides the sum of squared deviations by \(n-1\); in population mode, it divides by \(N\). OpenStax gives the same sample and population definitions and symbols. See OpenStax’s measures of spread.

    Choosing the correct standard deviation method
    Question Sample Population
    When to use it Your observations are a sample used to characterize or estimate a larger population. Your observations are the entire population you want to describe.
    Standard deviation symbol \(s\) \(\sigma\)
    Mean symbol \(\bar{x}\) \(\mu\)
    Variance denominator \(n-1\) \(N\)

    Sample standard deviation formula

    \[ s=\sqrt{ \frac{ \sum_{i=1}^{n}(x_i-\bar{x})^2 }{n-1} } \]

    Plain language: subtract the sample mean from each observation, square those deviations, add them, divide by one less than the sample size, and take the square root.

    The \(n-1\) denominator is commonly called Bessel’s correction. It makes the conventional sample variance unbiased for population variance under standard random-sampling assumptions; the square-rooted sample standard deviation itself is not generally exactly unbiased.

    Population standard deviation formula

    \[ \sigma=\sqrt{ \frac{ \sum_{i=1}^{N}(x_i-\mu)^2 }{N} } \]

    Plain language: find each observation’s deviation from the population mean, square and sum the deviations, divide by the population size, then take the square root.

    \(x_i\)
    An individual observation in the dataset.
    \(\bar{x}\)
    The arithmetic mean of a sample.
    \(\mu\)
    The arithmetic mean of the population being described.
    \(n\)
    The number of observations in the sample.
    \(N\)
    The number of observations in the population.
    \(s^2,\ \sigma^2\)
    Sample and population variance, expressed in squared data units.

    How to calculate standard deviation by hand

    1. Find the mean

      Add all observations and divide by the number of observations.

    2. Find each deviation

      Subtract the mean from every observation.

    3. Square the deviations

      Square each deviation so negative and positive differences do not cancel.

    4. Add the squared deviations

      This total is often called the sum of squares.

    5. Divide to get the variance

      Divide by \(n-1\) for a sample or by \(N\) for a population.

    6. Take the square root

      The square root of variance is standard deviation, which returns the measure of spread to the original data units.

    Standard deviation vs. variance

    Standard deviation and variance describe the same spread on different scales
    Standard deviationVariance
    Square root of varianceSquare of standard deviation
    Same units as the original dataSquared data units
    Usually easier to interpret directlyOften convenient in statistical formulas
    \(s\) or \(\sigma\)\(s^2\) or \(\sigma^2\)

    Check standard deviation in Excel

    For a sample, Excel uses =STDEV.S(range). For the complete population of interest, use =STDEV.P(range). Microsoft documents that STDEV.S uses the \(n-1\) method and recommends STDEV.P when the values represent the entire population. This is a useful independent check when your data already lives in a spreadsheet.

    Worked Standard Deviation Example

    The calculator loads the classic dataset 2, 4, 4, 4, 5, 5, 7, 9 as an example. In the default sample mode, it returns a sample standard deviation of about 2.1381. The same observations in population mode give exactly 2.

    Given values

    Dataset
    2, 4, 4, 4, 5, 5, 7, 9
    Count
    \(n=8\)
    Mode
    Sample standard deviation
    Find
    \(s\), with variance as a check

    Calculation

    1. Add the observations: the sum is 40, so the mean is \(\bar{x}=40/8=5\).
    2. Subtract 5 from each observation and square each deviation. The squared deviations are 9, 1, 1, 1, 0, 0, 4, and 16.
    3. Add the squared deviations: \(SS=32\).
    4. For sample variance, divide by \(n-1=7\): \(s^2=32/7\approx4.5714286\).
    5. Take the square root: \(s=\sqrt{32/7}\approx2.1380899\), displayed as 2.1381 with automatic precision.

    Result

    Sample standard deviation = 2.1381 data units

    The root-mean-square spread of the observations around the mean of 5 is 2.1381 data units under the sample standard deviation definition.

    How to Interpret Standard Deviation

    Standard deviation tells you the magnitude of spread, not whether that spread is automatically acceptable. A value is meaningful only in the context of the measurement units, the mean, the distribution shape, and the engineering or statistical decision you are making.

    Read it in the original units

    If the dataset is in millimeters, standard deviation is in millimeters. If measurements are in MPa, standard deviation is in MPa. Variance is different: it uses squared units such as mm² or MPa².

    Compare spread with context

    A standard deviation of 5 cannot be labeled universally “high” or “low.” Compare it with the scale of the measurements, expected process variation, measurement resolution, and any applicable acceptance criteria.

    Use the visual to inspect shape

    The calculator plots observations around the mean and marks mean ± 1 standard deviation. For large datasets, the display may summarize or sample plotted observations for readability while calculations continue to use the full accepted dataset.

    Normal-distribution interpretation is conditional

    You can calculate standard deviation for data that are not normally distributed. The familiar 68–95–99.7 rule is a separate interpretation that applies to an approximately normal distribution: about 68% of values are within one population standard deviation of the mean, about 95% within two, and about 99.7% within three. OpenStax’s standard normal distribution section states this normal-distribution condition explicitly.

    Z-scores put individual observations on the standard-deviation scale

    The calculator’s per-value results can report deviations and z-scores, with the displayed table limited for very large datasets to protect performance. A z-score describes how many calculated standard deviations an observation lies above or below the mean: positive values are above the mean and negative values are below it. A large absolute z-score signals distance from the mean, but it is not by itself proof that the observation is erroneous.

    Quartile conventions can change borderline IQR flags

    The calculator uses a median-of-halves quartile convention for Q1 and Q3. Other statistical packages may use interpolation-based quartiles, so a value close to an IQR fence can be flagged differently between tools even when the underlying dataset is identical. Treat the IQR result as a screening aid rather than an automatic data-deletion rule.

    Engineering use: variability is not the same as compliance

    NIST notes that manufacturing and measurement processes exhibit variability in quantities such as dimensions, thickness, and resistivity. Standard deviation is useful for quantifying that spread, but a single SD does not establish that a process is stable or that parts meet specification limits. Process-control decisions require the time structure of the data and an appropriate control-chart or statistical method; specification compliance requires the actual specification limits. NIST’s process variability guidance explains the distinction between stable controlled variation and changing uncontrolled variation.

    Common Mistakes and Important Limits

    Most bad standard deviation results come from defining the dataset incorrectly rather than from the arithmetic. Check these issues before treating the output as evidence about a larger process or population.

    Choosing sample or population by habit

    Define the population from the question you are answering. A complete set of 12 monthly observations can be a population if your question concerns exactly those 12 months, even though future months will exist.

    Mixing units or measurement conditions

    Do not combine inches with millimeters, or measurements taken under materially different conditions, without first converting or segmenting the data. Standard deviation assumes the numerical observations are comparable.

    Deleting a flagged outlier automatically

    The calculator can flag observations outside \(Q_1-1.5IQR\) or \(Q_3+1.5IQR\). NIST uses these inner box-plot fences for identifying unusual tail values, but a flag is a reason to investigate context, not an instruction to delete the observation. See NIST’s outlier guidance.

    Assuming more decimal places mean more accuracy

    The calculator keeps full internal precision and lets you change displayed decimal places. Reporting more digits does not improve the quality of the measurements or the representativeness of the sample.

    Treating a small sample as a precise estimate

    Sample standard deviation can be computed from two or more observations, but there is no universal sample-size threshold that makes the estimate “reliable.” Sampling design, population shape, desired confidence, and the decision being made determine how much data is enough.

    Confusing standard deviation with standard error

    Standard deviation describes spread among observations. Standard error describes sampling variability of a statistic. For the sample mean, OpenStax gives the population-standard-deviation form \(SE_{\bar{x}}=\sigma/\sqrt{n}\); the two quantities answer different questions.

    Ignoring drift or mixed operating states

    If a process mean changes over time, one pooled standard deviation can combine ordinary short-term variation with drift or regime changes. Segment, detrend, or model the time structure when the purpose is to characterize stable process noise.

    Assuming standard deviation proves normality

    It does not. Highly skewed, multimodal, or heavy-tailed data can have a perfectly valid standard deviation while the mean-and-SD summary hides important structure. Use the calculator’s quartiles and data-spread visual as additional evidence.

    Sources and Calculation Checks

    The guide and calculator use standard descriptive-statistics definitions. The worked example was independently checked by recomputing the mean, squared deviations, variance, and square-root result, then reversing the variance calculation back to the sum of squared deviations.

    Standard Deviation Calculator FAQ

    These answers cover practical follow-up questions that are not obvious from the result alone.

    Can standard deviation be negative?

    No. Variance is built from squared deviations and is therefore nonnegative; standard deviation is the nonnegative square root of variance. A result of zero occurs when every observation is identical.

    Can I paste frequency data into this calculator?

    Yes. Use value:frequency entries such as 10:3, 12:2, 15:1. Frequencies must be positive whole numbers. The calculator expands the frequencies and includes every represented observation in the same sample or population calculation.

    Why does sample mode require at least two observations?

    The sample variance denominator is \(n-1\). With one observation, that denominator becomes zero, so the conventional sample variance and sample standard deviation are undefined. Population mode can describe a one-value population, whose variance and standard deviation are both zero.

    How do I check the result in Excel?

    For sample data, Excel uses =STDEV.S(range). For the complete population of interest, use =STDEV.P(range). Microsoft documents that STDEV.S uses the \(n-1\) method and directs users to STDEV.P when the values represent the entire population.

    Does a larger standard deviation always mean worse performance?

    No. Standard deviation quantifies spread; it does not define what is acceptable. Whether greater variability is undesirable depends on the variable, units, engineering objective, specification limits, process behavior, and consequences of variation.

    Should I remove every value the IQR check flags?

    No. The 1.5 × IQR rule is a screening tool for unusual observations. Check for data-entry mistakes, measurement problems, changed operating conditions, or a genuine rare event before deciding whether exclusion is justified, and document any exclusion rule used in formal analysis.

    Why might this calculator and another program show slightly different outlier flags?

    Different software can use different quartile definitions. This calculator uses a median-of-halves method for Q1 and Q3, while some programs use interpolation. Standard deviation itself can still match even when a borderline IQR outlier classification differs.

    Scroll to Top