Focus keyword:
NPM package name checkerβ this article shows how to use NPM-GitNameCheck (CLI + library) to verify NPM package name availability and GitHub username/repo availability quickly, reliably, and in bulk.
TL;DR
If you need an NPM package name checker that also validates GitHub usernames and repositories, NPM-GitNameCheck is a CLI tool and Node library built for speed and auditability. It outputs TXT, JSON, and CSV reports, supports GitHub tokens for higher rate limits, and includes concurrency + retry logic to handle large lists.
Why run an NPM package name checker?
- Avoid brand collision: You don't want to publish a package with a name someone else owns.
- Consistent cross-platform branding: Make sure your package name matches your GitHub username or organization.
- Automate naming checks: Manual checking is slow and error-prone; integrate checks into CI/CD.
- Auditability: Keep CSV/JSON logs for proof your team checked names before launch.
Key features
- Checks NPM registry for package availability
- Validates GitHub usernames and repositories
- Outputs
free-names.txt,free-names.json, andnames-report.csv - Concurrency control, retries, exponential backoff, and jitter
- Supports GitHub tokens and proxies
- DNS-compliant name validation
Installation
# Global (recommended)
npm install -g npm-gitnamecheck
# Or as a local dependency
npm install npm-gitnamecheck
Quick start (example)
Create wordlist.txt:
myapp
cool-toolkit
brandx
superlib
Run:
npx npm-gitnamecheck wordlist.txt
Outputs:
-
free-names.txtβ a newline-separated list of available names -
free-names.jsonβ structured output with timestamps and services checked -
names-report.csvβ detailed log for auditing
Sample free-names.json:
[
{ "name": "myapp", "when": "2025-11-08T20:30:45.123Z", "services": ["npm","github:user"] }
]
Advanced usage
Use more concurrency and a GitHub token for higher throughput:
npm-gitnamecheck wordlist.txt \
--concurrency 30 \
--retries 5 \
--github-token ghp_yourtokenhere \
--out ./results
Notes:
- Without a token, GitHub limits you to 60 requests/hour (IP-based). With a token, limits jump to 5,000/hour per token.
- Be conservative with concurrency and use jitter/backoff to avoid being blocked.
Programmatic API (Node.js)
import { checkName } from 'npm-gitnamecheck';
(async () => {
const result = await checkName('myapp', { githubToken: process.env.GH_TOKEN });
if (result.ok) {
console.log('Available!');
} else {
console.log('Taken:', result.details);
}
})();
This lets you integrate the NPM package name checker directly into scripts, build pipelines, or web UIs.
Best practices & pitfalls
- Use a GitHub token for bulk checks. Donβt rely on anonymous requests for lists > 100 names.
- Respect API terms and rate limits. Aggressive scraping will get your IP or token blocked.
- Validate names first. Filter out invalid DNS names before checking to save requests.
- Cache results. If your CI checks the same list repeatedly, cache verified results to avoid waste.
- Log everything. Keep CSV results in your repo or artifacts for compliance and postmortems.
Example CI job snippet (GitHub Actions)
name: Name-check
on: [push, pull_request]
jobs:
check-names:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
- name: Install tool
run: npm install -g npm-gitnamecheck
- name: Run name checker
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: npx npm-gitnamecheck wordlist.txt --github-token $GH_TOKEN --out ./name-check-results
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: name-check-results
path: ./name-check-results
Where to go from here
- Fork the repo and open issues: https://github.com/FireXCore/npm-gitnamecheck
- Want PyPI, Docker Hub, or social handle checks? Add these as feature requests or PRs.
- Add progress bars, resume capabilities, or a GUI wrapper if you need desktop-friendly UX.
Closing / CTA
If you publish an NPM package or maintain open-source projects, integrate an NPM package name checker like NPM-GitNameCheck into your workflow before your launch checklist. Itβs a tiny step that prevents a massive brand headache later.
Try it now: npx npm-gitnamecheck wordlist.txt β then open names-report.csv and see the audit trail.
Author: Farbod Akvan β Full-Stack Developer & Open-Source Creator
Published by FireXCore β’ https://github.com/FireXCore/npm-gitnamecheck
Top comments (0)