How to Install Claude Code on Windows for Solo Developers
If you are a solo developer working on Windows, you have probably felt like a second-class citizen in the AI coding world. Most setup guides assume you are on macOS or Linux, leaving Windows users to reverse-engineer commands and troubleshoot cryptic errors. This guide fixes that. Below you will find a clear, step-by-step walkthrough for getting Claude Code running on Windows — both natively and through the Windows Subsystem for Linux (WSL) — without needing any DevOps background.
[IMAGE: Developer installing Claude Code on a native Windows terminal]
Why Windows Users Struggle with AI Coding Agents
AI coding agents like Claude Code were often built with Unix-first assumptions. That creates real friction for developers on Windows:
- Path handling differences — Windows uses backslashes (
\) while many tools expect forward slashes (/), which can break file resolution. - Terminal fragmentation — Between PowerShell, Command Prompt, and Git Bash, it is not always obvious which shell a tool expects.
- Documentation gaps — Many install instructions jump straight to Linux package managers with no Windows equivalent.
- Permission quirks — Windows execution policies can block scripts that run fine elsewhere.
The good news: Claude Code runs on Node.js, which is fully cross-platform. Once you understand the two supported paths — native Windows or WSL — installation becomes straightforward.
Prerequisites for Claude Code Windows Setup
Before installing anything, make sure your machine has the required foundations in place.
Node.js and npm Requirements
Claude Code is distributed through npm, so you need a working Node.js installation.
- Download the current LTS release of Node.js from the official Node.js website.
- Run the installer and accept the defaults — this installs both
nodeandnpm. - Verify the installation by opening PowerShell and running:
node --version
npm --version
If both commands return a version number, you are ready to proceed. If they do not, close and reopen your terminal so the updated PATH is picked up.
API Keys and Anthropic Account Setup
Claude Code connects to Anthropic’s models, so you need an account and authentication configured.
- Create or sign in to your Anthropic account.
- Generate an API key (or be ready to authenticate through the login flow Claude Code provides on first run).
- Keep the key somewhere secure — you will supply it during first launch. Never commit API keys to your repository.
Once Node.js and your Anthropic credentials are ready, you can install the tool.
Step-by-Step Installation Guide
There are two reliable ways to run Claude Code on Windows. Native installation is simplest for most solo developers; WSL is useful if your project already relies on a Linux toolchain.
Option 1: Native Windows via PowerShell/CMD
This is the recommended path for developers who want to stay entirely in the Windows environment.
- Open PowerShell (search for it in the Start menu).
- Install Claude Code globally with npm:
npm install -g @anthropic-ai/claude-code
- Once the install finishes, navigate into your project folder:
cd C:\Users\YourName\Projects\my-app
- Launch Claude Code:
claude
- On first launch you will be prompted to authenticate with your Anthropic account or API key. Follow the on-screen instructions.
If PowerShell blocks the script, you may need to adjust the execution policy for your user scope. Only change this if you understand the security implications, and prefer the least-permissive setting that works for your setup.
Option 2: Using Windows Subsystem for Linux (WSL)
If your workflow already depends on Linux tooling, running Claude Code inside WSL keeps everything consistent.
- Enable WSL from an elevated PowerShell window:
wsl --install
- Restart your machine when prompted, then set up your Linux distribution (Ubuntu is the default).
- Inside the WSL terminal, install Node.js using a Linux-friendly method such as a Node version manager.
- Install Claude Code the same way as native:
npm install -g @anthropic-ai/claude-code
- Move into your project directory and run
claude.
Tip: When using WSL, keep your project files inside the Linux filesystem rather than reaching across to the Windows C:\ drive. Cross-filesystem access is slower and can contribute to file recognition problems.
Verifying Your Setup
After installation, confirm everything is working before you start relying on the tool.
- Run
claude --versionto confirm the CLI is installed and on your PATH. - Launch
claudeinside a real project folder and ask it to summarize your codebase. If it can read your files and respond, your context is wired up correctly. - If Claude Code launches but cannot see your files, that is a separate configuration issue. You can troubleshoot file recognition issues in our dedicated guide to fix missing context problems.
With installation complete, the next step is getting your workspace properly configured. If you are new to the tool, work through our guide to configure your beginner setup so you can be productive on day one. To shape how the agent behaves in your project, learn to create a custom CLAUDE.md file that encodes your standards and conventions.
Frequently Asked Questions
Do I need WSL to run Claude Code on Windows?
No. Claude Code runs natively on Windows through PowerShell or Command Prompt as long as Node.js is installed. WSL is optional and mainly useful if your project already depends on a Linux toolchain.
What version of Node.js does Claude Code require?
Install the current LTS release of Node.js to stay compatible and supported. Using the LTS version avoids most installation and runtime issues on Windows.
Why does PowerShell block the Claude Code command?
Windows execution policies can prevent scripts from running. Adjusting the execution policy for your user scope typically resolves this, but only change it if you understand the security trade-offs.
Can I install Claude Code without an Anthropic account?
No. Claude Code connects to Anthropic’s models and requires authentication, either through an account login or an API key supplied on first launch.
Where should I keep my project files when using WSL?
Store project files inside the Linux filesystem rather than the Windows C:\ drive. This improves performance and reduces file recognition issues across the filesystem boundary.