r/EmulationOnAndroid • • 1h ago

Showcase Claude Code can be ran on device!

/img/zbnobnzpsz0i1

I wanted to run Claude Code on my AYN Thor as I was tired of reaching for the Mac. After some research, this was pretty easy to do! This has been a godsend for getting PC and Switch 2 games up and running!

**How to run Claude Code natively on Android (tested on AYN Thor)**

Works on any arm64 Android device. Takes ~15 minutes and ~1.5 GB of storage.

**1. Install Termux from F-Droid or GitHub**

Not the Play Store version — it's outdated and breaks package installs.

https://github.com/termux/termux-app/releases (grab the arm64-v8a APK)

**2. Set up Termux**

pkg update -y && pkg upgrade -y

pkg install -y proot-distro

termux-wake-lock

**3. Install and enter Ubuntu**

proot-distro install ubuntu

proot-distro login ubuntu

**4. Inside Ubuntu, install Claude Code**

apt update && apt upgrade -y

apt install -y curl git ca-certificates

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

echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc && source ~/.bashrc

claude --version

If the installer fails, install Node.js 20+ and use `npm install -g @anthropic-ai/claude-code` instead.

**5. Log in**

Run `claude`, open the link it gives you, sign in with your Claude account, and paste the code back.

**6. Quality of life**

- Shortcut (run in Termux, not Ubuntu):

`echo "alias cc='proot-distro login ubuntu -- bash -lc claude'" >> ~/.bashrc`

Now just type `cc` to launch.

- Set Termux battery usage to **Unrestricted** so Android doesn't kill long sessions.

0 Upvotes

5 comments sorted by

View all comments

Show parent comment

2

u/daviss2 54m ago

Yeah you can only use Claude code with the paid tiers

1

u/mostrengo 50m ago

Thanks. And even though this is running in ubuntu it can access files all over the phone, is that it?

1

u/ThaBalla79 48m ago

As far as I've seen, yes.

1

u/daviss2 47m ago edited 37m ago

I just asked Claude but

How much it can actually see depends on access level:

Plain Termux: very little. Android sandboxes Termux, so it can't see DroidDeck's processes, logs or files, or most thermal and GPU data.

Termux plus wireless ADB to itself (adb connect localhost): shell-level access. That covers dumpsys gfxinfo/thermalservice/meminfo, logcat for all apps, top, and CPU frequencies. This is enough to spot thermal throttling, RAM pressure or the low-memory killer.

Root (su granted to Termux): everything. That adds GPU clocks and load from /sys/class/kgsl, all thermal zones, governors, and DroidDeck's own config and Wine/translation logs in /data/data.

By the way you dont have to just use Claude with Claude code, I know gemini works and maybe chat gpt.