# Absolute Value Calculator

URL: https://speedycalculator.com/calculators/math/absolute-value/
Last updated: 2026-11-08

> The absolute value calculator gives |x|, the distance of a number from zero on the number line, and shows the sign that was removed.

## Inputs

- x
- Second number (for the distance |x − y|)

## Results

- |x|
- Distance |x − y|
- Sign of x

## Formula

```
|x| = x if x ≥ 0,  |x| = −x if x < 0
```

## Explanation

Absolute value strips the sign from a number, so |−7| = |7| = 7. It measures size or distance without direction: errors, tolerances, distances between points on a number line (|a − b|) and magnitudes of vectors all use it.

### How to use the Absolute Value Calculator

- **x**
- **Second number (for the distance |x − y|)**

Results update as you type, and everything is calculated in your browser.

### How it works

If the number is negative the calculator multiplies it by −1; otherwise it leaves it unchanged. The distance between two numbers is the absolute value of their difference.

### Inputs explained

FieldWhat to enterxA numberSecond number (for the distance |x − y|)A number

### What each result means

- **|x|** = abs([x])
- **Distance |x − y|** = abs([x] - [Second number (for the distance |x − y|)])

### Example values

How the main result changes when **x** changes and everything else stays at the example values above:

x|x|-3.633.625-5.445.4375-7.257.25-9.069.0625-10.8810.875-14.514.5

## Worked example

Inputs: x: -7.25; Second number (for the distance |x − y|): 3.

Results: **|x| = 7.25**; Distance |x − y| = 10.25; Sign of x = Negative.

## Key terms

- **Absolute value**: The distance of a number from zero.

## FAQ

**What is the absolute value of −3?**
3.

**Can an absolute value be negative?**
No. It is always zero or positive.

**What is**
a − b|? | The distance between a and b on the number line.

**Is**
a + b| = |a| + |b|? | Only when a and b have the same sign; in general |a + b| ≤ |a| + |b| (the triangle inequality).


## Sources

- [OpenStax: Prealgebra 2e](https://openstax.org/details/books/prealgebra-2e)
- [OpenStax: Contemporary Mathematics](https://openstax.org/details/books/contemporary-mathematics)
