Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
upstash avatar

Context7 Cli

  • 4.7k installs
  • 60.2k repo stars
  • Updated August 2, 2026
  • upstash/context7

Retrieve current, verified library documentation and AI coding skill management through a command-line interface.

About

The Context7 CLI (ctx7) provides three core workflows: fetch up-to-date library documentation via `ctx7 docs`, manage AI coding skills (install, search, generate, list, remove) through `ctx7 skills`, and configure Context7 MCP for AI coding agents with `ctx7 setup`. Developers use it when training data is outdated, when verifying API signatures, or when building agent workflows that require current reference material. The CLI resolves library identifiers, searches a centralized skill registry, and auto-suggests skills based on project dependencies. Authentication via OAuth or API key unlocks higher rate limits and skill generation. Works with npm/npx without local installation. Fetch current docs for any library without outdated training data Install, search, suggest, list, and generate AI coding skills from registry Configure Context7 MCP for Claude Code, Cursor, or OpenCode OAuth and API key

  • Fetch current docs for any library without outdated training data
  • Install, search, suggest, list, and generate AI coding skills from registry
  • Configure Context7 MCP for Claude Code, Cursor, or OpenCode
  • OAuth and API key authentication with rate-limit tiers
  • Auto-suggest skills based on project dependencies

Context7 Cli by the numbers

  • 4,702 all-time installs (skills.sh)
  • +288 installs in the week ending Aug 2, 2026 (Skillselion tracking)
  • Ranked #85 of 1,879 Documentation skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Aug 3, 2026 (Skillselion catalog sync)
At a glance

context7-cli capabilities & compatibility

free with rate limits; higher limits with login

Capabilities
fetch current library documentation by query · resolve library identifiers and manage api · install skills from github repositories · search centralized skill registry · auto suggest skills based on project dependencie · generate custom skills with ai (requires login) · configure mcp for ai coding editors
Works with
github
Use cases
documentation · code review · api development
Platforms
macOS · Windows · Linux
Runs
Runs locally
Pricing
Free
From the docs

What context7-cli says it does

The Context7 CLI does three things: fetches up-to-date library documentation, manages AI coding skills, and sets up Context7 MCP for your editor.
context7-cli.md
Use when writing code, verifying API signatures, or when training data may be outdated.
context7-cli.md
npx skills add https://github.com/upstash/context7 --skill context7-cli

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs4.7k
repo stars60.2k
Security audit1 / 3 scanners passed
Last updatedAugust 2, 2026
Repositoryupstash/context7

What it does

Fetch current library documentation and manage AI coding skills from the command line for Claude Code, Cursor, or OpenCode.

Who is it for?

Developers using Claude Code, Cursor, or OpenCode who need current documentation and want to build/manage reusable AI coding skills.

Skip if: Developers who only use web-based docs or who do not use MCP-compatible AI agents.

When should I use this skill?

User mentions ctx7 or context7, needs current library docs, wants to install/search/generate skills, or needs to set up Context7 MCP.

What you get

Access fresh library docs, install/search/generate skills, and configure MCP for AI coding agents - all from CLI.

  • Fetched library documentation
  • Installed AI coding skills
  • Context7 MCP configuration

By the numbers

  • Supports OAuth and API key authentication with rate-limit tiers
  • Integrates with Claude Code, Cursor, and OpenCode
  • Manages centralized AI coding skill registry

Files

SKILL.mdMarkdownGitHub ↗

ctx7 CLI

The Context7 CLI does three things: fetches up-to-date library documentation, manages AI coding skills, and sets up Context7 MCP for your editor.

Make sure the CLI is up to date before running commands:

npm install -g ctx7@latest

Or run directly without installing:

npx ctx7@latest <command>

What this skill covers

  • [Documentation](references/docs.md) — Fetch current docs for any library. Use when writing code, verifying API signatures, or when training data may be outdated.
  • [Skills management](references/skills.md) — Install, search, suggest, list, remove, and generate AI coding skills.
  • [Setup](references/setup.md) — Configure Context7 MCP for Claude Code / Cursor / OpenCode.

Quick Reference

# Documentation
ctx7 library <name> <query>           # Step 1: resolve library ID
ctx7 docs <libraryId> <query>         # Step 2: fetch docs

# Skills
ctx7 skills install /owner/repo       # Install from a repo (interactive)
ctx7 skills install /owner/repo name  # Install a specific skill
ctx7 skills search <keywords>         # Search the registry
ctx7 skills suggest                   # Auto-suggest based on project deps
ctx7 skills list                      # List installed skills
ctx7 skills remove <name>             # Uninstall a skill
ctx7 skills generate                  # Generate a custom skill with AI (requires login)

# Setup
ctx7 setup                            # Configure Context7 MCP (interactive)
ctx7 login                            # Log in for higher rate limits + skill generation
ctx7 whoami                           # Check current login status

Authentication

ctx7 login               # Opens browser for OAuth
ctx7 login --no-browser  # Prints URL instead of opening browser
ctx7 logout              # Clear stored tokens
ctx7 whoami              # Show current login status (name + email)

Most commands work without login. Exceptions: skills generate always requires it; ctx7 setup requires it unless --api-key or --oauth is passed. Login also unlocks higher rate limits on docs commands.

Set an API key via environment variable to skip interactive login entirely:

export CONTEXT7_API_KEY=your_key

Common Mistakes

  • Library IDs require a / prefix — /facebook/react not facebook/react
  • Always run ctx7 library first — ctx7 docs react "hooks" will fail without a valid ID
  • Repository format for skills is /owner/repo — e.g., ctx7 skills install /anthropics/skills
  • skills generate requires login — run ctx7 login first

Related skills

Forks & variants (1)

Context7 Cli has 1 known copy in the catalog totaling 23 installs. They canonicalize to this original listing.

How it compares

Use context7-cli when agents need live library docs or MCP wiring; use static skill files when documentation is bundled and version-pinned in-repo.

FAQ

Do I need to log in to use ctx7?

Most commands work without login. Only `skills generate` requires it. Login also unlocks higher rate limits on docs commands.

How do I fetch documentation for a library?

Run `ctx7 library <name>` first to resolve the library ID, then `ctx7 docs <libraryId> <query>` to fetch docs.

Can I use ctx7 without installing it globally?

Yes, run `npx ctx7@latest <command>` to use it directly without npm install.

Is Context7 Cli safe to install?

skills.sh reports 1 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

Documentationdocsintegrations

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.