Absolute value calculator

Type a number, plus or minus. Absolute value is the distance from zero on the number line. From −7 and from 7 you get 7. From 12.5 it stays 12.5. Zero stays zero.

Absolute value answers: “how far from zero?” Plus or minus does not matter - only size. So −7 and 7 both give 7.

Input

Result

Enter a number to see the result.

What it means

Picture the number line: zero in the middle, positives to the right, negatives to the left. Absolute value is distance from zero, with no question about which side. For a positive number you change nothing: |12| = 12. For a negative you drop the minus: |−12| = 12. Zero stays zero.

That is why −7 and 7 both give 7. |12.5| = 12.5. School notation is |x|. It helps when you care about “how much” and not “which way”: a measurement error, a miss from a target.

One Number field. Type −7 or 7, click Calculate. A comma and a period both parse. You can put the minus at the start. The result is always non-negative.

Percentage change uses |old| in the denominator so the sign of the result talks about up or down. Vector length uses squares, not this card. Here you keep one number and its distance from zero.

Without a number in Number, nothing computes. Typed 0 gives 0. The header does not change −7.

|−3.2| = 3.2. |100| = 100. |−0.5| = 0.5. Compare |−7| and |7| with the first card example.

Where it helps

  • Distance on the number line in school work.
  • How far a result is from a target (even if the difference is negative).
  • Formulas that need size, not sign.
  • “By how much” comparisons for rises and falls.

How to use

  1. Type a number in Number, with a comma or a period, positive or negative.
  2. Click Calculate. |−7| = 7. |12.5| = 12.5. |0| = 0.
  3. Put the minus at the start of the number. The result is non-negative.
  4. You can also click Fill this example under |−7| or |12.5|.
  5. Distance of vector (3, 4) lives on vector length. Here one number on the line.

Absolute value on the line

Absolute value measures distance from zero. From −7 and from 7 you get 7. In a notebook you write |x|, not a square bracket.

distance
Distance from zero, never negative. |−7| = 7 and |7| = 7. |0| = 0, because zero sits at the middle of the line.
zero
The origin of the number line. Which side you stand on does not enter the result, only how far you are from zero.
|x|
Vertical bars around x. In percentage change, |old| keeps the division base positive.

Examples

Example 1

  • Number: −7

7

The minus drops away. You keep the distance from zero.

Example 2

  • Number: 12.5

12.5

For a positive number, the result matches what you typed.

Example 3

  • Number: 0

0

Zero is already at zero, so the result is 0.

Example 4

  • Number: -7

7

What is |-7| and |7|? Both 7. The minus only names the side of zero.

Related calculators

FAQ

What is |−7|?

The absolute value is 7. The minus only says which side of zero you stand on, and the distance is the same as |7|.

What is |12.5|?

It stays 12.5. For a positive number absolute value does not trim anything, because you are already to the right of zero.

What is |0|?

The result is 0. Zero sits at the middle of the line, so the distance from zero is zero.

Can the result be negative?

No. Absolute value is non-negative by definition. The minus sign drops away and only the size remains.

Why |old| in percentage change?

So the sign of the percent speaks about direction, not about the sign of the base. You compute |x| here; the old and new pair lives on that other card.

What are |−3.2| and |−0.5|?

You get 3.2 and 0.5. A comma or a period is the same decimal, and the minus drops in both entries.

Is |−7| + |7| equal to 0?

No. Each absolute value is 7, so the sum is 14. The raw sum −7 + 7 would be zero, but here you strip the signs first.

How is this different from vector length?

Here one number on the line gives |x|. A vector (3, 4) builds length √(9+16) = 5 from two coordinates, on another calculator.

Do −0.0 and 0 give the same?

Yes. Both entries sit at zero, so the distance is 0.

How do I write this in a notebook?

Write |x| with vertical bars. A square bracket from an interval problem is a different mark and a different meaning.

Knowledge sources

The calculator computes the same formula as the definition below.

Page updated in 2026.