Skip to content

What Are Claude Code Skills and How Do I Install Them?

Problem

I used Claude Code daily, but I kept repeating the same prompts. Every session, I’d tell Claude about my coding style. Every project, I’d explain my testing requirements. Every code review, I’d specify my formatting preferences.

Here’s what my typical session looked like:

User: "Review this code. I use functional programming style, prefer immutable patterns, and need 80% test coverage. Also check for console.log statements."
Claude: "I'll review your code with those requirements..."

This worked, but I had to repeat myself constantly. Claude didn’t remember my preferences between sessions. Each new conversation started from zero.

I wanted:

  • Claude to automatically know my coding standards
  • Domain expertise without explaining it every time
  • Consistent behavior across all projects
  • Less time prompting, more time coding

What I Discovered

I found Claude Code Skills. Skills are pre-packaged prompts that make Claude a domain-specific expert. Unlike MCP servers which give Claude tool capabilities, Skills make Claude smarter about how to do things.

The difference is important:

┌─────────────────┐ ┌─────────────────┐
│ MCP Server │ │ Skill │
├─────────────────┤ ├─────────────────┤
│ Gives Claude │ │ Makes Claude │
│ new tools │ │ smarter │
├─────────────────┤ ├─────────────────┤
│ "Here's a │ │ "Here's how to │
│ hammer" │ │ build well" │
├─────────────────┤ ├─────────────────┤
│ File access │ │ Code review │
│ Web fetching │ │ TDD workflow │
│ Database query │ │ Security audit │
└─────────────────┘ └─────────────────┘

Skills are lightweight extensions installed via the npx CLI. Once installed, Claude automatically activates them based on context. No manual invocation needed.

My First Attempt (Failed)

I searched for a PDF skill and tried to install it:

terminal
npx skills find pdf

I got this output:

Found 3 skills matching "pdf":
1. pdf - Extract and analyze PDF documents
Installs: 1,234 | Rating: 4.8
2. pdf-formatter - Format PDFs for printing
Installs: 456 | Rating: 4.2
3. pdf-to-markdown - Convert PDFs to markdown
Installs: 789 | Rating: 4.5

I installed the first one:

terminal
npx skills add pdf -y

I got a success message:

Skill installed successfully: pdf
Location: ./node_modules/.claude-skills/pdf

I restarted Claude Code and tried to use the skill. Nothing happened. Claude didn’t recognize the skill at all.

The Mistake

I searched for why my skill wasn’t working and found the problem: I forgot the -g flag.

Local installation (npx skills add pdf -y) puts the skill in the current project’s node_modules. Claude Code doesn’t look there.

Global installation (npx skills add pdf -y -g) puts the skill in ~/.claude/skills/. That’s where Claude Code looks for skills.

The -g flag is required. Without it, Claude Code won’t see your skills.

The Correct Installation

I removed the local install and reinstalled globally:

terminal
# Remove local install
rm -rf ./node_modules/.claude-skills
# Install globally (required!)
npx skills add pdf -y -g

I got this output:

Skill installed globally: pdf
Location: ~/.claude/skills/pdf

Then I verified the installation:

terminal
npx skills list -g

Output:

Installed Skills (global):
1. pdf
Description: Extract and analyze PDF documents
Location: ~/.claude/skills/pdf
Status: Active

I restarted Claude Code. Now when I asked about a PDF, Claude automatically used the skill:

User: "What's in the document at ~/reports/q1.pdf?"
Claude: "[Skill: pdf activated]
I'll extract the content from your Q1 report..."

The skill triggered automatically. I didn’t have to invoke it manually.

How Skills Work

Skills work through auto-triggering based on keywords. When your message matches a skill’s trigger patterns, Claude activates that skill’s expertise.

For example, the PDF skill has triggers like:

  • File path ending in .pdf
  • Words like “PDF”, “document”, “extract”
  • Phrases like “what’s in this file”

The skill prompt is injected into Claude’s context before generating a response. This gives Claude specialized knowledge without you having to explain it.

Here’s the flow:

┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Your │────▶│ Skills │────▶│ Claude │
│ Message │ │ Matcher │ │ Response │
└─────────────┘ └─────────────┘ └─────────────┘
┌─────────────┐
│ Inject │
│ Skill │
│ Prompt │
└─────────────┘

Common Skills I Use

After understanding the installation process, I installed several skills:

terminal
# Search for useful skills
npx skills find code-review
npx skills find tdd
npx skills find security
# Install them globally
npx skills add code-review -y -g
npx skills add tdd-guide -y -g
npx skills add security-reviewer -y -g

My installed skills:

terminal
npx skills list -g

Output:

Installed Skills (global):
1. pdf - Extract and analyze PDF documents
2. code-review - Comprehensive code review with best practices
3. tdd-guide - Test-driven development workflow guide
4. security-reviewer - Security vulnerability detection

Now when I work, Claude automatically activates the right skill:

  • I mention “test” or “coverage” → tdd-guide activates
  • I ask to “review” or mention “clean code” → code-review activates
  • I mention “security”, “auth”, or “vulnerability” → security-reviewer activates

Common Mistakes

I made several mistakes learning to use skills. Here are the ones to avoid:

Mistake 1: Forgetting the -g flag

Terminal window
# WRONG: Local install, Claude won't see it
npx skills add pdf -y
# CORRECT: Global install, Claude will find it
npx skills add pdf -y -g

Mistake 2: Not restarting Claude Code

After installing a skill, you must restart Claude Code. The skills are loaded at startup, not dynamically.

Terminal window
# After installing a skill, restart Claude Code
# The skill won't work until you restart

Mistake 3: Installing too many skills

I installed 15 skills at first. This slowed down responses because Claude had to check all skill triggers for every message. I reduced to 4-5 core skills and saw faster responses.

Mistake 4: Expecting manual invocation

Skills auto-trigger. You don’t type /pdf or invoke them manually. Just use natural language and the skill activates based on context.

Updating Skills

Skills receive updates like any package. I update mine weekly:

terminal
npx skills update

Output:

Checking for updates...
Updated:
- pdf: 1.0.0 -> 1.1.0
- code-review: 2.0.0 -> 2.1.0
No updates available for:
- tdd-guide
- security-reviewer

Finding Skills

The official marketplace is at skills.sh. You can browse by category, see install counts, and read ratings.

terminal
# Search by keyword
npx skills find api
npx skills find testing
npx skills find documentation
# See detailed info
npx skills info pdf

You can also search the marketplace directly:

  • Visit https://skills.sh
  • Browse categories or search
  • Copy the install command
  • Run with -y -g flags

Skills vs MCP Servers

A common question: when should I use skills vs MCP servers?

Use MCP Servers when you need Claude to:

  • Access files on your system
  • Query databases
  • Make HTTP requests
  • Use external tools

Use Skills when you need Claude to:

  • Follow specific workflows
  • Apply coding standards
  • Use domain expertise
  • Follow best practices
┌──────────────────────────────────────────────────────────┐
│ Claude Code │
├─────────────────────────┬────────────────────────────────┤
│ MCP Servers │ Skills │
├─────────────────────────┼────────────────────────────────┤
│ filesystem-server │ code-review │
│ postgres-server │ tdd-guide │
│ fetch-server │ security-reviewer │
├─────────────────────────┼────────────────────────────────┤
│ Gives Claude TOOLS │ Gives Claude KNOWLEDGE │
└─────────────────────────┴────────────────────────────────┘

Both can work together. My setup includes MCP servers for tool access and skills for domain expertise.

Summary

In this post, I explained Claude Code Skills and showed how to install them correctly. The key points are:

  • Skills are pre-packaged prompts that make Claude a domain-specific expert
  • Always use the -g flag for global installation
  • Restart Claude Code after installing skills
  • Skills auto-trigger based on keywords in your messages
  • Keep 4-5 core skills to avoid slowing down responses
  • Use skills for knowledge, MCP servers for tools

Skills eliminated my repetitive prompting. Now Claude automatically applies the right expertise based on what I’m doing. I spend less time explaining my requirements and more time coding.

Final Words + More Resources

My intention with this article was to help others share my knowledge and experience. If you want to contact me, you can contact by email: Email me

Here are also the most important links from this article along with some further resources that will help you in this scope:

Oh, and if you found these resources useful, don’t forget to support me by starring the repo on GitHub!

Comments