What Is Semantic Versioning (SemVer)?
Semantic Versioning is a version numbering convention in the format MAJOR.MINOR.PATCH, where each segment signals a specific kind of change to consumers of a...
Published October 8, 2026
Semantic Versioning uses MAJOR.MINOR.PATCH numbers: bump MAJOR for breaking changes, MINOR for new backward-compatible features and PATCH for backward-compatible bug fixes.
The concept
Version 2.4.1 means major 2, minor 4, patch 1. Consumers can read the number and know the upgrade risk.
Ranges in package managers use it: ^1.2.3 allows 1.x.x, ~1.2.3 allows 1.2.x. Pre-release tags look like 1.0.0-beta.1.
What to bump
1.4.2 → 1.4.3 bug fix
1.4.3 → 1.5.0 new feature, compatible
1.5.0 → 2.0.0 breaking change
Practical examples
npm ranges
{ "dependencies": { "a": "^1.2.3", "b": "~1.2.3", "c": "1.2.3" } }Bump with npm
npm version patch
npm version minor
npm version majorGit tags
git tag v1.5.0 && git push --tagsCommon mistakes
- Making breaking changes in a minor release.
- Staying on 0.x forever (0.x gives no stability promise).
- Not documenting breaking changes.
Key takeaways
- MAJOR.MINOR.PATCH.
- Major = breaking.
- Use ranges deliberately.
FAQ
What does ^ mean?
Compatible with the version, allowing changes that do not modify the left-most non-zero digit.
Is 1.0.0 special?
It signals a stable public API.