npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

npm-dependency-verifier

v1.2.0

Published

A command line tool that verifies all dependencies and devDependencies in your package.json file against the npm registry.

Readme

NPM Dependency Verifier

A command line tool that verifies all dependencies and devDependencies in your package.json file against the npm registry.

Features

  • Verifies package existence on npm registry
  • Checks if specified versions are available
  • Suggests closest available version when version is not found
  • Recommends similar package names when package does not exist
  • Automatically fixes issues with various modes
  • Color coded output for easy reading

Installation

npm install -g npm-dependency-verifier

Usage

Navigate to your project directory (where package.json is located) and run:

Verify Only

verify-deps

This will scan all dependencies and report any issues without making changes.

Fix All Issues

verify-deps --fix-all

Fixes both package name errors and version mismatches by updating package.json with the closest available versions and most similar package names.

Fix Version Issues Only

verify-deps --fix-version

Only updates version numbers to the closest available version. Package names remain unchanged.

Fix Package Name Issues Only

verify-deps --fix-name

Only updates incorrect package names with suggested alternatives. Version numbers remain unchanged.

Output

Examples

Valid Dependency

[email protected]

Version Not Found

[email protected]
  ▍ Version 18.5.0 does not exist for react
  ▍ Closest version available: 18.2.0

Package Not Found

[email protected]
  ▍ This package does not exist
  ▍ Did you mean: express

How It Works

  1. Reads package.json from the current directory
  2. Fetches package metadata from npm registry (https://registry.npmjs.org)
  3. Verifies each package exists
  4. Checks if the specified version is available
  5. Calculates closest available version using semantic versioning
  6. Searches for similar package names using npm search
  7. Reports findings with detailed suggestions
  8. Optionally updates package.json with fixes

Requirements

  • Node.js 12.0.0 or higher
  • npm (for package search functionality)
  • Internet connection (to access npm registry)

Error Handling

The tool handles various error scenarios:

  • Missing package.json file
  • Network connectivity issues
  • Invalid package.json format
  • npm registry timeouts
  • Malformed version strings

Version Matching

The tool preserves version prefixes when suggesting replacements:

  • ^1.2.3 becomes ^1.2.5 (if 1.2.3 does not exist)
  • ~2.0.1 becomes ~2.0.2 (if 2.0.1 does not exist)
  • 1.0.0 becomes 1.0.1 (exact version replacement)

Package Name Suggestions

When a package is not found, the tool uses npm search to find similar packages based on:

  • String similarity algorithms
  • Search relevance from npm registry
  • Download popularity

Contributing

Contributions are welcome. Please ensure:

  • Code follows existing style
  • All features are tested
  • Documentation is updated
  • Commit messages are clear

License

MIT