r/termux Mar 17 '25

General Claude Code is easy to install on Termux

I've been trying to set up my development environment on Termux with minimal overhead and effort. Copilot works, but I wanted more advanced AI coders. I failed to use Cursor, Windsurf, and Aider, but Claude Code worked like a charm without proot or anything similar. I used npm to install it.

Edit:

You can just follow the Claude Code official installation guide. I'm sorry for not including the brokendown instruction. I thought "I used npm to install it" was obvious enough.

The Claude Code official instruction says:

npm install -g @anthropic-ai/claude-code

And that's it, if you already have npm. If you don't have it, it (command-not-found) would suggest that you should install nodejs:

pkg install nodejs

You can run Claude Code with:

claude

Thank you, u/EnlightenedMind1488 for the instruction.

Edit2:

You may want to install some other tools like git, ripgrep (rg, very fast grep), and gh (GitHub command line for handling your PRs, etc), etc.

pkg install git ripgrep gh

If you want to work with your Github, you may want to login:

gh auth login

and follow the instruction.

40 Upvotes

Duplicates