major: 1 minor: 2 patch: 3 prerelease: beta.4 build: build
About Semver Calculator — Compare Versions & Test Ranges
Semantic Versioning (semver) encodes meaning into a version number: `MAJOR.MINOR.PATCH`, where a major bump signals breaking changes, minor adds backward-compatible features, and patch ships fixes. Optional prerelease (`-alpha.1`) and build (`+build.5`) suffixes refine that further. Getting the precedence rules right matters when you reason about dependency bumps, lockfile resolution, or which release ships first.
This free semver comparator parses any version into its parts, compares two versions for precedence (including the tricky prerelease ordering, where `1.0.0-alpha` sorts before `1.0.0`), tests whether a version satisfies an npm-style range (`^`, `~`, `>=`, x-ranges), and bumps a version by release type. Everything runs entirely in your browser — nothing you type is uploaded.
Features
- Parse a version into major, minor, patch, prerelease and build
- Compare two versions with correct prerelease precedence (build metadata ignored)
- Test ranges: ^, ~, >=, <=, >, <, =, and x-ranges
- Bump a version by major, minor, patch or prerelease — fully offline
How to use
- Pick an action: Parse, Compare, Satisfies, or Bump.
- For Parse/Bump, enter a version (Bump takes the release type on line 2).
- For Compare/Satisfies, enter two values one per line (version + version, or version + range).
- Read the verdict and explanation in the output pane, then copy the result.
Frequently asked questions
How does prerelease precedence work?
A version with a prerelease has lower precedence than the same version without one, so 1.0.0-alpha < 1.0.0. Prerelease identifiers are compared left to right: numeric ones are ordered numerically, alphanumeric ones lexically, and numeric identifiers rank below alphanumeric ones.
Is build metadata used for ordering?
No. Per the SemVer 2.0.0 spec, build metadata (everything after a "+") is ignored when determining precedence. 1.0.0+a and 1.0.0+b compare as equal.
What is the difference between ^ and ~ ranges?
Caret (^1.2.3) allows changes that do not modify the left-most non-zero version part — typically >=1.2.3 <2.0.0. Tilde (~1.2.3) allows patch-level changes only — >=1.2.3 <1.3.0. For 0.x versions, caret tightens to the minor.
Does this tool send my versions anywhere?
No. All parsing, comparison and range testing happens locally in your browser with a hand-rolled implementation of the SemVer spec. Your input never leaves your device.
Related tools
Everything runs locally in your browser — your input is never uploaded.