# Claude Code 'Raw Mode Is Not Supported' on Windows? Match the Error First

> Raw mode is not supported, 'claude' is not recognized, 32-bit Windows, Exec format error on WSL1 — five different Windows startup failures that get treated as one problem. Each has a distinct cause and a distinct fix, and four of them aren't install failures at all.

By Tahir Nazir · Published 2026-08-21 · Updated 2026-10-12
Canonical: https://www.its-tahir.com/blog/claude-code-raw-mode-is-not-supported-windows

**`Raw mode is not supported` means Claude Code couldn't get a real interactive terminal: you launched it from Git Bash, or piped input into it. The install is fine. Start it from PowerShell or Windows Terminal instead, or use `claude -p "your prompt"` for non-interactive runs.**

Five different Windows failures get lumped together as "it won't install." They are not the same problem, and generic install guides send you in circles because they cover only one of them. **The error text tells you which one you have** — start there rather than reinstalling.

| What you see | Actual cause |
| --- | --- |
| `Raw mode is not supported` | Git Bash, or piped stdin — not the install |
| `'claude' is not recognized` | PATH, or a terminal opened before the install |
| `Claude Code does not support 32-bit Windows` | You opened the PowerShell **(x86)** shortcut |
| `cannot execute binary file: Exec format error` | WSL1 |
| `syntax error near unexpected token` followed by HTML | A proxy returned a login page |

Four of the five are environment problems wearing an installation costume. Reinstalling fixes none of them.

![Five Claude Code Windows startup errors with cause and fix: Raw mode is not supported (Git Bash or piped stdin), 'claude' is not recognized (PATH), Claude Code does not support 32-bit Windows (PowerShell x86), cannot execute binary file: Exec format error (WSL1), and syntax error near unexpected token followed by an HTML page (proxy login page)](https://www.its-tahir.com/blog/claude-code-raw-mode-is-not-supported-windows/windows-startup-errors.svg)

*Match the error text before reinstalling: four of the five are environment problems, not a broken install.*

## `Raw mode is not supported` — two different triggers

This is the one that dominates the search results, and it isn't an install problem. The install worked.

### Trigger 1: you launched it from Git Bash

An interactive terminal UI needs **raw mode** — the ability to read keypresses one at a time instead of waiting for a newline. That requires a real TTY, and Git Bash on Windows doesn't provide the TTY features the interactive CLI needs. You hit the error before you even finish authenticating.

The fix isn't to abandon Git Bash. It's to **launch from PowerShell and let the CLI call Git Bash internally** for the commands it runs. You keep the Unix tooling; you just stop hosting the interactive UI in a terminal that can't support it.

That split matters on Windows, because the installer wants both — it will tell you so with `Claude Code on Windows requires either Git for Windows (for bash) or PowerShell`. In practice you want PowerShell to run *in*, and Git for Windows to shell out *to*.

### Trigger 2: you piped something into it

If you get the same error in PowerShell, look at your command rather than your terminal:

```bash
# Cannot work — a pipe is not a TTY
echo "explain this repo" | claude
```

Raw mode requires stdin to be a TTY, and a pipe isn't one. That's exactly what [issue #5925](https://github.com/anthropics/claude-code/issues/5925) reports. For non-interactive use, pass the prompt as an argument:

```bash
claude -p "explain this repo"
```

`-p` runs in print mode: it answers and exits without ever trying to enter raw mode. Anything scripted, piped, or running in CI wants that flag — there's no terminal in a CI job for raw mode to attach to either.

## `'claude' is not recognized`

The install reported success and the command doesn't exist. The wording differs by shell, which is worth knowing when you're searching for it:

| Shell | Error |
| --- | --- |
| Windows CMD | `'claude' is not recognized as an internal or external command` |
| PowerShell | `claude : The term 'claude' is not recognized as the name of a cmdlet` |

Both mean the install directory isn't on your PATH. On Windows the binary lands here:

```text
%USERPROFILE%\.local\bin\claude.exe
```

Before editing any environment variables: **close the terminal and open a new one.** PATH changes apply to new shells only, so the window that ran the installer still has the old PATH and will keep failing no matter how many times you reinstall. The same root cause shows up as the installer completing but `claude` reporting an old version.

## `does not support 32-bit Windows` on a 64-bit machine

Genuinely confusing, and the cause is a Start menu entry.

Windows ships **two** PowerShell entries: `Windows PowerShell` and `Windows PowerShell (x86)`. The x86 entry runs as a 32-bit process and triggers this error even on a 64-bit machine. Confirm it in the same window that produced the error:

```powershell
[Environment]::Is64BitOperatingSystem
```

If that prints `True`, your OS is fine and you opened the wrong shortcut. Close it, open `Windows PowerShell` **without** the x86 suffix, and install again.

## `Exec format error` in WSL

If `claude` in WSL prints `cannot execute binary file: Exec format error`, you're on **WSL1**, hitting a known native-binary regression tracked in [issue #38788](https://github.com/anthropics/claude-code/issues/38788) — the binary's program headers changed in a way WSL1's loader can't handle.

The clean fix is converting the distribution, from PowerShell:

```powershell
wsl --set-version <DistroName> 2
```

Staying on WSL1 is possible by invoking the binary through the dynamic linker, but converting is the supported path and removes a class of problems rather than one.

## HTML where a script should be

Your install command downloaded a web page instead of a script:

```text
bash: line 1: syntax error near unexpected token
bash: line 1: <!DOCTYPE html>
```

On PowerShell the same thing surfaces as parse errors quoting HTML tags or CSS, sometimes as `Missing expression after unary operator` or a `ParserError`. HTML in the error text is the tell.

This is a network problem, not a tooling one — usually a corporate proxy or captive portal returning a login page. Saving with `-OutFile` doesn't help, because the saved file is that same page.

## Then decide: native Windows or WSL?

Once it starts, there's a second choice with a consequence most comparisons miss.

**On WSL, searching across the Windows filesystem silently returns fewer matches than it should — and `claude doctor` still reports Search as OK.** No error, no warning, just an agent that appears not to understand your codebase. If you use WSL, keep the project on the Linux filesystem under `/home/` rather than `/mnt/c/`.

I develop on Windows natively for that reason. I covered that failure and the other silent ones in [why Claude Code goes slow, hangs, or eats memory](/blog/why-claude-code-is-slow-hanging-or-eating-memory). Controlling what these tools can see about a project on Windows is the same problem [ContextZero](/work/contextzero) came out of.

## When none of the rows match

Run the built-in check before reinstalling anything:

```bash
claude doctor
```

It checks your installation, settings, extensions and context usage, and proposes fixes it can apply after you confirm. Use `claude doctor` from your shell when it won't start, and `/doctor` inside a session when it starts but misbehaves.

**Key takeaways**

- Raw mode is not supported is not an install failure. Git Bash cannot provide a TTY — launch from PowerShell and let the CLI call Git Bash internally.
- The same error in PowerShell means you piped input. Use claude -p with your prompt instead of echoing into it.
- 'claude' is not recognized is usually a terminal that was already open. PATH changes apply to new shells only.
- does not support 32-bit Windows on a 64-bit machine means you opened the PowerShell (x86) Start menu entry.
- Exec format error means WSL1. Convert the distro to WSL2 rather than working around the loader.

Read the error, match it to the row, and you're usually two minutes from working. The reason these take people an afternoon is that the loudest search results all assume the same cause, and four times out of five that assumption is wrong.

If your servers start but their tools never appear, that's a different class of problem — [MCP server not showing up in Claude Code](/blog/mcp-server-not-showing-up-in-claude-code) covers it, including the Windows `cmd /c` fix that trips up npm-distributed servers.

If a local server or MCP server won't start with `EACCES` or WinError 10013 on a port nothing is using, Windows has reserved that port: [here's how to see the reserved ranges and get it back](/blog/winerror-10013-port-forbidden-windows).

Once it starts, the errors that follow — proxies, model 404s, token limits, auto mode — are all indexed in [Claude Code not working? Every error and its fix](/blog/claude-code-troubleshooting).

## FAQ

### Why does Claude Code say Raw mode is not supported in Git Bash?

Git Bash does not provide the TTY features an interactive terminal UI needs. The CLI requires raw mode to read keypresses one at a time, and Git Bash cannot supply it, so the CLI exits before you finish authenticating. Launch Claude Code from PowerShell instead and let it use Git Bash internally for the commands it runs.

### I get Raw mode is not supported even in PowerShell. Why?

You are almost certainly piping input into claude. Raw mode requires stdin to be a TTY, and a pipe is not one. For non-interactive use, pass the prompt with the -p flag rather than piping it in — print mode answers and exits without ever entering raw mode.

### Why is claude not recognized after the install said it succeeded?

The install directory is not on your PATH, or you are still in a terminal that was open when the installer ran. On Windows the binary lands in your user profile under .local\bin. PATH changes apply to new shells only, so close the terminal and open a new one before concluding the install failed.

### Should I use WSL or native Windows for Claude Code?

Native Windows avoids a real and silent problem: on WSL, searching across the Windows filesystem returns fewer matches than expected while claude doctor still reports Search as OK. If you do use WSL, keep the project on the Linux filesystem under /home/ rather than /mnt/c/, and use WSL2 rather than WSL1.

## Sources

- [Troubleshoot installation and login — Claude Code docs](https://code.claude.com/docs/en/troubleshoot-install)
- [Troubleshooting — Claude Code docs](https://code.claude.com/docs/en/troubleshooting)
- [CLI crashes with Raw mode is not supported when piping input (issue #5925)](https://github.com/anthropics/claude-code/issues/5925)
- [Exec format error on WSL1 (issue #38788)](https://github.com/anthropics/claude-code/issues/38788)
