New Tool Radar

AI for Data & Spreadsheets

How to Set a Data Validation Number Range in Google Sheets

Add a number-range data validation rule in Google Sheets so out-of-range scores are rejected at entry.

Schematic illustration for How to Set a Data Validation Number Range in Google Sheets: three numbered steps - Select the number column; Data, Data validation, Is between; Test an out-of-range value.

A test score of 150 in a column that should hold 0 to 100 is a typing error that will poison an average, and it is far cheaper to reject it at entry than to find it later. A number-range validation rule in Google Sheets refuses values outside the range, or warns about them, at the moment they are typed.

Prerequisites

  • Google Sheets
  • A column that should hold numbers in a known range
  • A copy of the source file, so the original stays untouched.

Steps

  1. Select the cells in the number column, then go to Data, Data validation, Add rule.
  2. Under Criteria, choose Is between, and enter the minimum and maximum, for example 0 and 100.
  3. Under Advanced options, choose Reject the input so an out-of-range value cannot be entered.
  4. Click Done, then test the rule by typing a value above the maximum and confirming it is refused.
  5. Check the existing values in the column for any that already fall outside the range.

Worked example: Fictional quiz scores with a 0 to 100 rule

The practice table below is a fictional five-student quiz list. The score column is the quiz result, and the total is their sum. The table below is fictional practice material, with fictional values. It is the expected result, worked out by hand, not a run of any tool.

Student Score
Amara 72
Ben 68
Clara 88
Dev 59
Elena 81
Total 368

Expected result. Five scores, each between 0 and 100, and the scores add to 368.

Limits

  • A rule set to show a warning instead of rejecting will still let bad values in, so choose reject for strict ranges.
  • A pasted range can bypass validation in some cases, so check pasted data after import.

Sources

See all