Skip to main content

Troubleshooting

2 min read

Solutions to common Claude Code issues and how to resolve them


title: Troubleshooting description: Solutions to common Claude Code issues and how to resolve them

Having issues with Claude Code? This guide covers common problems and their solutions to get you back on track quickly.

Installation Issues

Command Not Found

If you get "command not found" after installing Claude Code:

Solution 1: Check your PATH

Bash

Solution 2: Verify installation location

Bash

Solution 3: Reinstall globally

Bash

Permission Denied Errors

When npm install fails with EACCES errors:

Solution: Fix npm permissions

Bash

Node.js Version Issues

If you see errors about unsupported Node.js versions:

Bash

Authentication Problems

Login Failures

If claude auth login fails or times out:

Check network connectivity:

Bash

Clear cached credentials:

Bash

API Key Issues

If you're using an API key instead of OAuth:

Bash

Session Expiration

If your session keeps expiring:

Bash

Runtime Errors

Out of Memory

If Claude Code crashes with memory errors:

Increase Node.js memory limit:

Bash

For large codebases:

Use .claudeignore to exclude unnecessary files:

Text

Slow Performance

If Claude Code is running slowly:

1. Check file count:

Bash

2. Reduce context size:

Bash

3. Clear cache:

Bash

Connection Timeouts

If requests time out frequently:

Bash

Configuration Issues

Settings Not Applied

If changes to .claude/settings.json don't take effect:

1. Validate JSON syntax:

Bash

2. Check file permissions:

Bash

3. Restart Claude Code:

Bash

MCP Server Connection Failures

If MCP servers won't connect:

1. Check server configuration:

JSON

2. Test the server manually:

Bash

3. Check for port conflicts:

Bash

Custom Commands Not Working

If slash commands don't appear:

1. Check file location:

Bash

2. Verify file format:

Bash

IDE Integration Issues

VS Code Extension Problems

Extension not loading:

Bash

Extension can't find Claude CLI:

Bash

Terminal Issues in IDE

Terminal not responding:

  1. Kill any stuck Claude processes:
Bash
  1. Restart the integrated terminal

  2. Check terminal profile settings in IDE

Platform-Specific Issues

macOS

Gatekeeper blocking execution:

Bash

Keychain access issues:

Bash

Linux

Missing dependencies:

Bash

Windows (WSL)

WSL clipboard issues:

Bash

Path issues:

Bash

Getting Help

Diagnostic Information

Collect this information before seeking help:

Bash

Where to Get Help

Reporting Bugs

When reporting issues, include:

  1. What you were trying to do
  2. The exact error message
  3. Steps to reproduce
  4. Your environment (OS, Node version, Claude version)
  5. Relevant configuration files (redact sensitive data)

Quick Fixes Checklist

Before diving deep, try these quick fixes:

  • [ ] Restart Claude Code
  • [ ] Update to latest version: npm update -g @anthropic-ai/claude-code
  • [ ] Clear cache: rm -rf ~/.claude/cache
  • [ ] Re-authenticate: claude auth logout && claude auth login
  • [ ] Check network: curl https://api.anthropic.com/v1/health
  • [ ] Verify configuration: claude config show

Next Steps

Generated with AI using Claude AI by Anthropic

Model: Claude Opus 4.5 · Generated: 2025-12-20 · Build: v1.21.0-75762dc

Edit this page on GitHub··

Discussion

0/2000

Comments are reviewed before being published