Strategist · Designer · Operator

Launch
with Ben



Claude Code

I Turned a Raspberry Pi 5 Into a Claude Code Box. Three Things Broke First.

The cheap version of the Mac mini + Claude setup: a Raspberry Pi 5 running Claude Code headless on a subscription. What the kit left out, the 32-bit trap, and a script that checks all of it.


Claude Code runs on a Raspberry Pi 5. It took a couple of detours to get there.

Everyone’s doing the Mac mini + Claude thing right now: a little box on a shelf that runs an agent while you sleep. I wanted to see how cheap I could do it. So I bought a Raspberry Pi 5 kit, put Claude Code on it, and logged in with my normal subscription.

It works. claude --print answers from the Pi over SSH, and there’s no API key anywhere. Getting there wasn’t quite plug and play, though. The kit was missing a few things, and the first install failed with an error that sent me looking in the wrong place.

$173all in, kit plus what I added
0API keys. The Pro/Max login works headless
1re-flash, because the card shipped 32-bit

The budget kit is basically just the Pi

I bought PiShop’s Raspberry Pi 5 Budget Kit, 4GB (SKU K2B-1323-4GB, $144.95 on the listing today). In the box: the board, a case, the 27W power supply and a microSD card with the OS already on it. That’s it.

Unless you already have a micro-HDMI cable, a monitor or TV, and a keyboard lying around, you can’t do much the first time you power it on. The Pi 5 uses micro-HDMI, so your normal HDMI cable won’t fit. The instruction sheet also mentions heat sinks for three chips. There weren’t any in the box.

Amazon to the rescue. About $30 and two days later I had everything:

What I boughtWhyPaid
Micro-HDMI to HDMI cableTo see the first boot on a screen$6.79
microSD to USB-C readerTo re-flash the card from my laptop (more on that below)$6.60
GeeekPi Armor Lite V5 (heatsink and fan)The kit has no cooling at all$11.99
CAT6 Ethernet cableTurned out I didn’t need it$2.99

The Ethernet cable was a just-in-case buy. The Pi joined my Wi-Fi on its own, which was a nice surprise. Skip it unless your Wi-Fi is flaky.

Most of this is a one-time thing. After setup I never touch the monitor or keyboard again. I SSH in from my laptop and start Claude inside tmux, so the session keeps running when my laptop closes. The cooler is the only add-on that stays on the board.

The 32-bit card that broke the installer

The installer is one line:

curl -fsSL https://claude.ai/install.sh | bash

On the card that came with the kit, it failed:

Setting up Claude Code...
bash: line 226: /home/benp/.claude/downloads/claude-2.1.284-linux-arm64: cannot execute: required file not found

“Required file not found,” on a file that was obviously there. I assumed a bad download. It wasn’t. Two commands showed what was actually going on:

uname -m                    # aarch64
dpkg --print-architecture   # armhf

Receipt My kit card ran a 64-bit kernel on a 32-bit userland. The installer failed until I re-flashed it.

The kernel was 64-bit, but everything running on top of it was 32-bit. The installer saw the 64-bit kernel and grabbed the 64-bit Claude Code binary, which can’t run on a 32-bit system. That’s what the “file not found” was about. It wasn’t Claude Code’s fault.

And the kit listing actually says so, if you read it closely: “SanDisk microSD Card with Raspberry Pi OS 32-bit.” I didn’t read it closely. The same thing has tripped up Ollama users on the Pi too.

The fix was re-flashing the card to Raspberry Pi OS (64-bit) with Raspberry Pi Imager, which is what the card reader was for. Tip: set the hostname, user, Wi-Fi and SSH in Imager’s settings before you write the card, and you don’t need a monitor at all. The annoying part is that re-flashing wipes everything, so every package, the gh auth login and the git clone had to be done again. Check the architecture before you install anything.

Logging in without a browser just worked

This is the part I expected to be a pain. People have been asking how to log Claude Code in on ARM64 and headless machines since at least February, and an open issue says the login URL can’t even be copied out over SSH. The workarounds floating around involve generating a token on another computer, or copying credential files over.

On Claude Code 2.1.284 I didn’t need any of that. Run claude once over SSH, pick the subscription login, and it prints a URL and a code:

  1. claude prints a login URL and a code
  2. I open the URL and enter the code
  3. it waits for the approval
  4. I approve the login on my account
  5. claude is logged in
  6. claude --print answers from a script

One thing to watch for. An hour earlier, GitHub’s CLI had offered “Press Enter to open github.com in your browser.” On a Pi with no screen, that opened a text-only browser right inside my SSH window: GitHub’s sign-in page as plain text, full of dead ends and awful to get around. So when Claude showed its link, I didn’t press Enter on anything. I just copied the URL to my phone.

Then the test that actually matters, because it’s what a scheduled job calls:

claude --print "Say hello in exactly 5 words."
# Hello there, nice to meet you!

Receipt Run over SSH on my Pi 5 with a Pro/Max login, Claude Code 2.1.284. No API key. About ten seconds a call.

No setup-token, no ANTHROPIC_API_KEY. The Pro/Max login works for non-interactive calls too. If you’re comparing that to paying for the API, the price difference is the whole reason to want this.

A script to check your Pi first

I rolled all of the above into one script. It only reads, it doesn’t install or change anything. Run it on the Pi before the installer, and again after:

curl -fsSL https://launchwithben.com/tools/pi-claude-check.sh | bash
bash pi-claude-check.sh --auth    # also makes one real claude --print call

Receipt Read-only. Catches the 32-bit userland that cost me a re-flash, plus RAM, throttling, and whether claude runs.

What it checks

Do

  • Kernel and userland are both 64-bit. This is the one that would have saved me the re-flash
  • Board model and RAM
  • Any overheating or power problems since boot
  • The claude binary actually runs, not just that it’s installed
  • With --auth, one real claude --print call on your login

How it’s holding up

Here’s the same set of checks, run by hand on the finished box:

$ cat /proc/device-tree/model
Raspberry Pi 5 Model B Rev 1.1
$ uname -m; dpkg --print-architecture
aarch64
arm64
$ free -h
               total        used        free      shared  buff/cache   available
Mem:           4.0Gi       1.5Gi       809Mi        76Mi       1.8Gi       2.4Gi
Swap:          2.0Gi          0B       2.0Gi
$ vcgencmd measure_temp; vcgencmd get_throttled
temp=52.1'C
throttled=0x0
$ time claude --print "Reply with exactly: ok"
ok
real	0m10.246s

4GB is plenty. Claude Code itself is light, since the actual model runs on Anthropic’s servers. With two Claude sessions open in tmux, the whole Pi used 1.3GB and had 2.6GB free, and the two sessions were about 925MB of that. A --print call takes around ten seconds, which doesn’t matter for a job on a timer. throttled=0x0 means it hasn’t hit a heat or power limit since boot.

The fan only kicks in when it needs to. It was spinning at 2,622 RPM at 52°C right after that claude --print call, and completely off later when the Pi was idling at 49.9°C. Idle is most of its day, so the $11.99 cooler is really for the busy moments.

What it runs, and what I haven’t checked yet

There’s one line in the crontab:

*/15 * * * * cd /home/benp/raspi && ./runbook.sh

Every fifteen minutes it runs whatever jobs are due. That shows it’s scheduled. It doesn’t show the jobs actually succeed, and I haven’t followed a real one through on this box yet. I also don’t know how the subscription login holds up after weeks of cron with nobody logging in. That’s for a follow-up.

The 32-bit card is a lot like trusting docs that don’t match the code: the kernel told the truth, it just wasn’t the thing that was broken.

Related:

Sources

  • PiShop.us, Raspberry Pi 5 Budget Kit, 4GB: price, SKU and the “Raspberry Pi OS 32-bit” card, read 2026-09-28.
  • anthropics/claude-code #27405: how to authenticate on ARM64 and headless machines (closed as a duplicate, February 2026).
  • anthropics/claude-code #83316: headless login where the OAuth URL can’t be copied over SSH (open).
  • ollama/ollama #4577: the same 32-bit userland failure with a different tool.
  • Raspberry Pi Imager: used for the 64-bit re-flash.
Ben Peetermans

Ben Peetermans

I build MVPs and run ad campaigns with AI, and I write these notes from real projects. Twenty years shipping for the web. If you want someone who works with these tools every day to build yours, that is what I do.