MAE Calculator
Calculate mean absolute error between predicted and actual values.
About MAE Calculator
Mean Absolute Error (MAE) is the average magnitude of prediction errors, without regard to direction: MAE = (1/n) × Σ|y_i − ŷ_i|. It's expressed in the same units as the target variable, making it easy to interpret directly (e.g. 'predictions are off by $500 on average'). Unlike MSE/RMSE, MAE weighs all errors linearly, so it's less sensitive to outliers — a few very bad predictions won't dominate the score as much as they would with squared-error metrics.
Formula
MAE = (1/n) * sum(|y_i - y_hat_i|)
- n
- Number of samples
- y_i
- Actual value for sample i
- \hat{y}_i
- Predicted value for sample i
Worked example
With the default values below, MAE Calculator returns Mean Absolute Error of 0.5000. Change any input above and every figure here is recalculated in your browser.
Inputs used
- Actual Values
- 3, -0.5, 2, 7
- Predicted Values
- 2.5, 0.0, 2, 8
Results
- Mean Absolute Error
- 0.5000
- Number of Samples
- 4
Step by step
- 1Sum of absolute errors: Σ|y_i − ŷ_i|= 2.0000
- 2MAE: sum of absolute errors / n= 0.5000
Assumptions and limits
- The result is derived only from the 2 inputs listed above. Anything not among them is not part of the calculation.
- In particular, this calculator does not take inflation, tax, fees or charges or compounding frequency into account.
- Figures are rounded for display to 4 decimal places, so totals built from several rounded parts can differ slightly from the unrounded arithmetic.
How these calculators are built and tested is described on the Methodology page. If a figure looks wrong, please report it.
Frequently Asked Questions
How is MAE different from MSE?
MAE averages the absolute value of errors (linear penalty), while MSE averages squared errors (quadratic penalty) — MSE punishes large errors much more heavily, so MAE is more robust to outliers.
What does a lower MAE mean?
A lower MAE means predictions are, on average, closer to the actual values — MAE of 0 would mean perfect predictions with no error at all.
Is MAE sensitive to the scale of the target variable?
Yes — MAE is expressed in the same units as the target, so a MAE of 5 means something very different when predicting house prices in dollars versus predicting a 0-1 probability; use MAPE for a scale-independent alternative.
