ForHosting KIT · Math

Range calculator

For the list 3, 7, 2, 9 and 5 the range is 7: the maximum 9 minus the minimum 2. Paste any numbers, negatives and decimals included, and get the count, the smallest and largest value and the span between them. Free in your browser.

  • Free
  • Runs in your browser
  • No sign-up
  • Your data stays on your device
Use it from WebAPIEmailTelegramApp soon
If you enter
Values
3, 7, 2, 9, 5
You get
N
5
Min
2
Max
9
Range
7

The statistical range is the simplest measure of spread: subtract the smallest number in a list from the largest. Students, analysts, and quality-control scripts reach for it when they need one honest width for a sample without fitting a distribution or computing variance. This range calculator accepts a non-empty array of finite numbers, finds the minimum and the maximum in a single linear pass, and returns the difference as range together with the count, min, and max so you can audit the extremes.

What the statistical range means and how it is computed

The range of a numeric list is the difference between its maximum and its minimum. In symbols, if the observations are x one through x n, then range equals max of x minus min of x. That single difference answers a narrow but common question: how wide is this set from end to end?

It does not describe clustering, skew, or typical distance from the mean; it only reports the span between the two extremes. A small range means every value sits close to the others on the number line; a large range means at least one observation is far from another, even if most of the mass is tight. Introductory statistics courses present range before variance and interquartile range because it needs no squares, no sorting into quartiles, and no divisor debate about n versus n minus one.

When every entry is identical, min equals max and range is zero, which is correct mathematics. When the list has a single finite number, the same identity holds: that one value is both the minimum and the maximum, so range is zero. Empty lists are a different case entirely.

Duplicate values are allowed and do not change the definition; only the extremes matter. Negative numbers, zeros, and mixed signs are first-class: the maximum of minus four and ten is ten, the minimum is minus four, and the range is fourteen.

Because every step is a comparison and a subtraction of known finite numbers, the procedure is classical and fully deterministic: the same list always yields the same min, max, and range, which makes the numbers safe to pin in automated tests, lesson answer keys, and reproducible notebooks without Monte Carlo noise.

Practical use, limits, pricing, and delivery

Use the browser tool when you want an immediate min, max, and range while checking a homework answer, profiling a small dataset, or explaining spread before introducing variance, without installing a statistics package. Accepted lists stay bounded: up to one hundred thousand values cover classroom tables, sensor batches, and typical analytics excerpts while still finishing quickly. Results are fully deterministic: the same values always yield the same n, min, max, and range.

There is no language model, no external statistics service, and no randomness, so the capability is safe to pin in continuous-integration checks and reproducible lesson materials. Keep lists modest for everyday classroom and dashboard use; the hundred-thousand ceiling is a guardrail against accidental bulk dumps, not a target.

When you also need quartiles, an interquartile range, or a five-number summary in the same sitting, call the dedicated tools for those search intents; this landing stays focused on the statistical range so the page and the response contract stay honest about what they deliver.

Homework and introductory statistics labs

Students and graders verify min, max, and range for the same list, including the hard rule that an empty list is invalid and a singleton has range zero.

Quality control and sensor batches

Engineers turn a finished batch of readings into a stable min, max, and range for reports and automated oracles without opening a spreadsheet formula.

What happens if the list is empty?

At least one finite number is required to compute the range. Validation failures are not charged.

Does a list of one number have a range?

Yes. That single value is both the minimum and the maximum, so range is zero. A singleton is valid; an empty list is not.

How is range different from interquartile range or standard deviation?

Range uses only the two extremes (max minus min). Interquartile range uses quartiles; standard deviation uses squared distance from the mean. Those are separate tools.

Is the range calculator free?

The browser tool runs free on your device.

Does the range work with negative numbers?

Yes. Negative values, zeros and mixed signs are all fine: for −4 and 10 the maximum is 10, the minimum is −4 and the range is 14.

Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.

POSThttps://api.kit.forhosting.com/stat/range

Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.

curl -X POST https://api.kit.forhosting.com/stat/range \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"values":[3,7,2,9,5]}'
{
  "values": [
    3,
    7,
    2,
    9,
    5
  ]
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "stat.range",
  "status": "queued",
  "_links": {
    "result": "/tasks/tsk_…/result"
  }
}

The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

max_values100000
HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

Empty lists fail with invalid_input instead of a silent zero that would pretend missing data still has a spread. The same deterministic parse module powers the free in-browser tool and the API path at $0.002 per successful request, with no language model, no network call, and no randomness on the hot path.

What the statistical range means and how it is computed

The trade-off is sensitivity: a single outlier sets one of the two endpoints and can dominate the result, which is why later chapters introduce more robust spread measures. This calculator stays honest about that textbook definition. It walks the list once, tracks the running minimum and maximum, subtracts, and returns those three numbers plus the count n. There is no largest or smallest element of the empty set in this contract, so the engine refuses to invent a range and fails with invalid_input.

Input contract, response shape, and validation rules

On success the body returns n (the count of accepted numbers), min, max, and range (max minus min), plus a short formula string restating range equals max minus min for clients that log which identity produced the row. There is no requirement that numbers lie in a particular interval such as zero to one hundred: any finite magnitude within a published safe bound is accepted, so temperatures, prices, residuals, and signed sensor readings compute a truthful span without preprocessing. POST a JSON object with a required values field: a non-empty array of finite numbers, at least one entry and at most one hundred thousand. Aliases accepted for the same list include numbers, data, list, and x, so scripts that already speak in those terms do not need a rename step. Each element may be a JSON number or a numeric string; non-finite values, empty strings, booleans, and non-numeric tokens fail with invalid_input naming the bad index. You may also pass values as a single comma- or whitespace-separated string when a text form is more convenient than a JSON array. Missing values, an empty array, more than one hundred thousand entries, or a body that is not an object all raise invalid_input and are not billed. Pair this contract with a dedicated quartile, variance, or five-number-summary tool if you need a richer description of spread; this endpoint reports the textbook max-minus-min range only.

Practical use, limits, pricing, and delivery

Each successful request is one billable item at $0.002; failed validation does not consume balance. Wire the endpoint into data-science tutorials, spreadsheet-migration tests, coding-interview sandboxes, or preprocessing steps where you already prefer a closed-form one-pass range over opaque calculators that hide whether they dropped missing cells or treated an empty column as zero.

Scripts and CI numeric fixtures

Pipelines and interview sandboxes call a deterministic range contract instead of reimplementing max-minus-min in every language with different empty-list behavior.

How do I compute the statistical range of a list of numbers?

Send JSON with values (a non-empty array of finite numbers) to stat.range. The response returns n, min, max, range, and formula. Range is max minus min.

Read the full KIT documentation →