Package.json Dependency Updater
Analyze and update package.json dependencies with version strategies
About this ToolHow it works, benefits & use casesTap to collapse
Paste a package.json and this tool reads its dependency tree, then rewrites version ranges to whatever update policy you pick. "Analyze dependencies" parses your dependencies and devDependencies, counts them, and classifies each entry by range type — caret (^), tilde (~), exact, range, or latest — so you can see at a glance how loose or pinned your manifest is. "Update versions" then rewrites every range to a single strategy: caret to allow minor and patch updates, tilde for patch-only, exact to lock to a precise version, or latest. It returns a clean, re-indented package.json you can paste straight back, plus a list of ready-to-run update commands for npm, Yarn, or pnpm. It works on the JSON you give it — no registry calls — so your manifest never leaves the browser.
How to Use
- 1Choose a version strategy (Caret, Tilde, Exact, or Latest) and your package manager (npm, Yarn, or pnpm) from the two dropdowns.
- 2Paste your package.json into the input panel, or click "Load example" to try the sample manifest.
- 3Click "Analyze dependencies" to see counts and the per-package range type for dependencies and devDependencies.
- 4Click "Update versions" to rewrite every range to your chosen strategy and get a clean package.json back.
- 5Copy the updated package.json, or copy the generated update commands to run in your project root.
Key Benefits
- Classifies every dependency by range type — caret, tilde, exact, range, or latest
- Counts dependencies and devDependencies separately with at-a-glance stats
- Rewrites all ranges to one consistent strategy in a single click
- Returns clean, re-indented JSON ready to paste back into your project
- Generates the matching update commands for npm, Yarn, or pnpm
- Built-in strategy guide explains what caret, tilde, exact, and latest mean
- Works entirely on your pasted JSON — no network or registry lookups
Common Use Cases
- Standardising a messy manifest where some deps use ^, some ~, and some are pinned
- Locking every dependency to an exact version before a production release
- Loosening pins to caret ranges so a project can pick up minor updates
- Auditing how many dependencies vs devDependencies a project actually has
- Generating the right yarn upgrade or pnpm update command for a batch of packages
Update settings
Paste your package.json — dependencies and devDependencies will be extracted.
Version strategy guide
- Caret (^):
- Allows minor and patch updates (e.g., ^1.2.3 matches 1.x.x)
- Tilde (~):
- Allows patch updates only (e.g., ~1.2.3 matches 1.2.x)
- Exact:
- Locks to a specific version (e.g., 1.2.3)
- Latest:
- Always uses the latest version (not recommended for production)
Was this tool helpful?
Share Your Experience
Help others discover this tool!
Related tools
- Package.json GeneratorBuild a complete package.json with framework presets, scripts, deps, exports map, engines, and live validation
- Badge GeneratorBuild shields.io README badges with live preview, assemble a badge row, and export Markdown, HTML, reStructuredText or AsciiDoc
- Semantic Versioning HelperParse, bump, and compare semver, plus a range tester (^ ~ x hyphen ||) and changelog generator
- License CheckerVerify package licenses and ensure compliance with your project license
- Package.json Scripts GeneratorGenerate common npm scripts for different project types and workflows
- npm to Yarn ConverterConvert npm commands and package-lock.json to Yarn equivalents
Caret (^1.2.3) allows minor and patch updates within the same major version. Tilde (~1.2.3) allows patch updates only. Exact (1.2.3) locks to one precise version. Latest replaces the range with the keyword "latest" — handy for tooling but not recommended for production because it floats freely.
No. It does not contact the npm registry — it works only on the version numbers already in your package.json. "Update versions" rewrites the existing version (stripping the old prefix) to the prefix your chosen strategy uses; it does not look up what the actual latest release is.

