Boneyard Tools

Semver Range Checker

Enter a version and a semver range to see at a glance whether it matches. Supports caret, tilde, comparators, x-ranges, hyphen ranges, AND and OR, plus a breakdown of the parsed version parts.

How to check a semver range

  1. Type the version you want to test, for example 1.4.2.
  2. Type a range such as ^1.0.0, ~1.2.0 or >=1.0.0 <2.0.0.
  3. Read the yes or no result and the parsed major, minor, patch and prerelease parts.

Examples

Caret range

version 1.4.2 against ^1.0.0
satisfies: true (any 1.x at or above 1.0.0, below 2.0.0)

Caret on a 0.x version

version 0.3.0 against ^0.2.0
satisfies: false (^0.2.0 is locked to the 0.2 minor)

Range with two bounds

version 1.5.0 against >=1.0.0 <2.0.0
satisfies: true

Frequently asked questions

What do the caret (^) and tilde (~) mean?

Caret allows changes that do not modify the left-most non-zero version part. ^1.2.3 allows >=1.2.3 and <2.0.0, while ^0.2.3 is locked to 0.2 and allows <0.3.0. Tilde allows patch-level changes when a minor is given: ~1.2.3 allows >=1.2.3 and <1.3.0.

Which range syntax is supported?

Exact versions, caret (^1.2.3), tilde (~1.2.3), comparators (>, >=, <, <=, =), x-ranges (1.x, 1.*, 1), hyphen ranges (1.2.3 - 2.3.4), the wildcard *, space-separated AND, and || for OR.

How are prerelease versions handled?

A prerelease like 1.0.0-alpha ranks below its release 1.0.0. Following the npm rule, a prerelease only matches a range when a comparator names that same major.minor.patch with a prerelease, so ^1.0.0 will not pick up 1.2.3-beta by accident.

How does it compare two versions?

It compares major, minor and patch as numbers, then compares prerelease identifiers one by one. Numeric identifiers sort numerically and rank below alphanumeric ones, and a longer identifier set wins when all earlier parts are equal. Build metadata after + is ignored for ordering.

Is my data sent to a server?

No. Parsing, comparison and range matching all run entirely in your browser. Nothing you type is uploaded.

Does it follow the official Semantic Versioning spec?

Yes. Version parsing and precedence follow semver.org, and the range operators follow the widely used node-semver conventions for caret, tilde, hyphen and x-ranges.

Related tools