Skip to content

// guides

Coding on Android: The Complete 2026 Guide

Coding on Android in 2026 is real, and it is the most capable of the mobile platforms for it. There are four honest paths: a real on-device Linux terminal with Termux, an SSH client like Termius or ConnectBot pointed at a machine you own, a browser IDE such as vscode.dev or GitHub Codespaces in Chrome, or a native cloud terminal like Cosyra for Android. Unlike an iPad, where the local options are emulated or sandboxed, an Android phone runs a genuine Linux userland on the metal — apt, Python, Node, the lot. We wrote this because the phone in your pocket is a more serious dev machine than its reputation, and the right pick depends on whether you need offline compute, an existing server, or zero setup with AI agents already installed.

This is the pillar page for the Android coding topic. If your device is an iPad rather than a phone, start with coding on iPad: the complete guide; if it is an iPhone, the story is different, because iOS has no on-device Linux userland the way Android does. On a Chromebook the picture shifts again: ChromeOS ships Crostini, a real local Debian container, so it is the one mobile-class device with first-class on-device Linux. For the agent-first picture across Claude Code, Codex CLI, OpenCode, and Gemini on mobile, that pillar goes deeper on agent-driven work, and the mobile coding terminal guide covers the terminal layer across phones in general. Sign up gets you 1 hour free, no credit card.

Quick decision — pick the path that matches your constraint:

  • You want free, offline, on-device Linux — Termux gives you a real APT shell with no server and no subscription. Termux path ↓
  • You already run an always-on Linux machine — an SSH app plus Mosh connects you to it from the phone. SSH path ↓
  • You want x86_64 Linux with AI agents and zero setup — a native cloud terminal runs an Ubuntu container with no phantom killer. Two-minute setup ↓
  • You just want the verdict — the decision framework picks for you from three questions. Decision framework ↓

Prefer to weigh them side by side? Jump to the full comparison table ↓.

What makes coding on Android different from an iPad or a desktop?

One thing changes everything: Android lets a real Linux userland run on-device. Termux is not an emulator and not a WebAssembly sandbox — it is an Android terminal emulator wired to a native APT package set, so pkg install python nodejs git openssh gives you the actual tools running on the phone's own CPU. That is the line iPadOS will not let you cross; there the local options are iSH's 32-bit x86 emulator or a-Shell's WASM-compiled bundle, both slow or sandboxed. On Android the local path is a first-class option, not a consolation prize.

The flip side is the two things Android takes away. The userland is ARM (aarch64), not x86_64, so a long tail of precompiled wheels and glibc-only native modules do not run. And on Android 12 and later the phantom-process killer governs background work, which means a long agent session or a build can get cut off mid-run. Those two facts shape every decision below: they are exactly what you trade away when you stay local, and exactly what a remote x86_64 machine hands back.

Is Android good for coding, or does the OS get in the way?

Android is good for coding and the OS gets in the way, both at once — just in different places than iPadOS does. The chip in a recent flagship is plenty; a Pixel 8 or a Galaxy S24 runs a Node build without breaking a sweat. What bites is process management. The Termux README carries a standing warning that Android 12+ may be unstable because the OS kills any app spawning more than 32 phantom processes or using heavy CPU, and users hit it as [Process completed (signal 9) - press Enter]. It is fixable on Android 14+ under Developer Options, and we wrote up the exact steps in the Termux signal 9 fix, but it is a real tax on long sessions.

The second constraint is the ABI. Termux builds for aarch64 and armv7, so most of the ecosystem works, but the edges do not: x86-only Python wheels, glibc-assuming native Node packages, a real Docker daemon, and kernel modules. None of this means "you cannot code on Android." It means the local path has a ceiling, and once you hit it the answer is to reach a real x86_64 Linux machine over the network — your own, or a hosted one. We've run every path below on a Pixel 8 over the last year, and each has a specific shape of friction.

What are the four ways to code on Android?

The four approaches are Termux on-device, an SSH client connected to your own server, browser IDEs like vscode.dev and GitHub Codespaces in Chrome, and native cloud terminals like Cosyra. The right pick depends on whether you value local and offline compute, existing infrastructure, browser-based editing, or zero-setup reach to a real x86_64 Linux box.

1. Termux on the phone itself

Termux is the reason Android coding is a genuine topic and not a workaround. It is open source (GPLv3), free, and installs from F-Droid (Android 7+) or Google Play (Android 11+), with the F-Droid build at v0.118.3 as of 2026-06-13. You get Bash, fish, or Zsh; nano, Emacs, or Vim; OpenSSH, curl, rsync; and current Python, Ruby, Perl, and Node.js, plus Clang and CMake for Go, Rust, and C builds. The AI agents install too: Claude Code goes on via npm install -g @anthropic-ai/claude-code plus a shell alias, a path we cover in full in Claude Code on Android.

When Termux is the right pick: you want everything local and offline, you do not want a subscription, and you are happy to do per-tool setup. When it breaks: x86-only binaries, anything needing a real Docker daemon, and long sessions on Android 12+ that the phantom killer ends. For the full local-Linux picture including proot-distro and UserLAnd, see Linux container on Android, and for the head-to-head against a cloud box, Cosyra vs Termux.

2. SSH from Android to your own machine

This is the classic answer and still the best one if you already own an always-on Linux box. Termius and the open-source ConnectBot are the polished Android SSH clients; pair one with Tailscale for zero-config networking and tmux so the session survives app switches, and you have a stable pipe to a real machine. Termux can also just be your SSH client — its OpenSSH is the same one you would use on a laptop.

The failure mode is always the server. Your desktop sleeps, your home power blips, your ISP rotates the IP and the port forward dies. You are on the bus, the laptop lid closed twenty minutes ago, and the session you needed is not there. We kept hitting those stories ourselves, which is part of why we built a cloud-first alternative. When SSH is the right pick: you run reliable hardware, you have keys and shell config the way you like, and you would rather own the environment than pay for a managed one.

3. Browser IDEs (vscode.dev, GitHub Codespaces)

GitHub Codespaces and vscode.dev run in Chrome on Android. The editor and file tree render fine, but a phone screen is a cramped place to read a tree-plus-editor-plus-diff layout, and the browser sandbox has no integrated terminal or debugger in vscode.dev — you can edit and commit, but you cannot run the code without a backend, and Codespaces compute is metered (GitHub Free includes 120 core-hours a month, then from $0.18/hr for a 2-core machine, as of 2026-06-05). For the head-to-head against a native terminal, see Cosyra vs VS Code for the Web and Cosyra vs Codespaces on mobile.

4. Native cloud terminal (Cosyra)

The fourth path is a native Android app that opens a real Linux machine. We run a per-user Ubuntu 24.04 x86_64 container on Azure AKS, reached from the Android app, with Claude Code, Codex CLI, OpenCode, and Gemini CLI pre-installed, 30 GB of persistent storage, and session hibernation so locking the phone does not cost you the container. It is BYOK — you bring your own Anthropic, OpenAI, or Google key. Because the work runs on a Linux host rather than under Android's process governor, the phantom killer never enters the picture, and the x86_64 ABI means every Ubuntu binary and wheel just works. The tradeoff is honest: this needs a network, it is not offline, and it is a paid product after the free hour. What you get back is no server to babysit, no ARM edge cases, and no emulation tax.

Try it free. 1 hour on signup, no credit card. A real x86_64 Ubuntu container with four AI agents pre-installed, opened from a native Android app. Google Play / App Store / Pricing details

How do the Android coding options compare?

The table below is the side-by-side we use when someone asks which Android coding setup to pick. Prices and facts are dated; every competitor row is grounded in a factsheet we re-verify on a schedule.

Feature Termux (local) SSH + your box Codespaces (Chrome) Cosyra (cloud app)
Price Free Free app + your server 120 free core-hrs, then metered $29.99/mo after free hour
Native Android app Yes Yes No (Chrome only) Yes
Real x86_64 Linux No (ARM userland) Depends on server Yes Yes (Ubuntu 24.04)
AI agents pre-installed No (install via npm) No No (install yourself) Yes (4 agents)
Integrated terminal Yes Yes No (browser sandbox) Yes
Offline capable Yes No No No
Phantom-killer risk Yes (Android 12+) No (runs on server) No (runs in cloud) No (runs in cloud)
Persistent storage On device Your server Yes (hibernates) Yes (30 GB, always-on)
Setup time 10-30 min per tool 30-60 min 2 min (in browser) ~2 min
API key model Local only Your server GitHub-managed BYOK (you own keys)
Open source Yes (GPLv3) Partial No No

Which Android coding setup should you pick?

Three questions settle it. First: do you want everything local, offline, and free? If yes, Termux is the answer, and you accept the ARM userland and the phantom killer as the price of no server and no subscription. If no, the next question is whether you already run an always-on Linux machine: if yes, SSH from Termius or ConnectBot to it. If you do not have a server and you want x86_64 with AI agents already installed and no phantom killer, a cloud terminal app gives you the machine without the babysitting; if you only ever edit and commit, a browser IDE is enough. The flowchart below is the same logic.

Decision flowchart for coding on Android: pick a path based on whether you want local offline Linux, already run an always-on machine, or need x86_64 with AI agents. Four outcomes: Termux on-device, SSH from Termius or ConnectBot, a cloud terminal app, or a browser IDE.
Decision flowchart for picking an Android coding setup in 2026. Built by the Cosyra team from hands-on testing on a Pixel 8 running Android 14 with Termux v0.118.3 (created 2026-06-25).

How do you set up a real x86_64 dev environment on Android in two minutes?

The fastest path to a real x86_64 Linux box on Android is the native app route, because there is no pkg install marathon and no server to stand up first. Install Cosyra from Google Play, sign in, and the Ubuntu container provisions on first launch. The terminal session below is what the first two minutes look like once it is up.

cosyra on a Pixel 8, first 2 minutes after install

$ # Cosyra installed from Google Play, container provisioned on launch

$ # Confirm it is real x86_64 Ubuntu, not ARM

$ uname -m && lsb_release -ds

x86_64

Ubuntu 24.04.1 LTS

 

$ # Verify the agents are pre-installed

$ claude --version

Claude Code v2.1.170

 

$ # Bring your own key, then start coding

$ echo 'export ANTHROPIC_API_KEY="sk-ant-..."' >> ~/.bashrc && source ~/.bashrc

$ git clone https://github.com/your-org/app.git

$ cd app && claude

Claude Code — type a prompt, review the diff, accept, push.

That is the whole loop, and the uname -m line is the point: x86_64, not the aarch64 Termux reports, so every Ubuntu binary and Python wheel installs without an ARM caveat. Because the container hibernates rather than resetting, you can lock the phone, ride a few stops, and reopen to the same session. For the agent-specific Android walkthrough, the Claude Code on Android guide and the Codex CLI on Android guide cover each agent's quirks.

What does a real Android coding session look like?

A real session is short and reviewed. We unlock the phone on the bus, prop it against a coffee cup, or hold it one-handed in a queue, type a prompt to the agent, watch it propose a change, and read the diff. The work that fits a phone well is the work where the agent does the heavy typing and you do the deciding: bug fixes, small features, dependency bumps, code review on a branch, a quick script. The work that fits badly is anything that wants a local native toolchain — a GPU job, a local Docker compose stack, or an IDE plugin with no web build.

The honest opinion we will plant a flag on: the phone keyboard is fine for agent-driven coding, because you are writing prompts and reading diffs, not typing thousands of lines. Most people who say "you can't really code on a phone" are picturing themselves hand-writing a function on glass, not steering an agent that does the typing for them. And on Android specifically, the "can't" is mostly habit: Termux has run real Linux on the device for a decade, and a cloud container removes even its rough edges. The thing stopping more developers from coding on the train is that nobody told them the phone was ready.

Which Android guide should you read next?

This pillar stays general on purpose. For the tool you actually use, we have a device-specific Android guide that goes deeper on setup, quirks, and what breaks:

tl;dr

Four ways to code on Android. Pick Termux for free, offline, on-device Linux if you accept an ARM userland and the Android 12+ phantom killer. Pick SSH (Termius / ConnectBot) if you already run a Linux machine. Pick vscode.dev or Codespaces if you only need to edit and commit in Chrome. Pick Cosyra if you want a native Android app into a real x86_64 Ubuntu container with AI agents pre-installed and no phantom killer.

Google Play / App Store. Sign up — 1 hour free, no credit card. Extend with a 10-hour, 7-day trial when you want more.

Get a real x86_64 Linux dev box on your Android phone in two minutes. Install Cosyra, sign in, and the Ubuntu container with Claude Code, Codex CLI, OpenCode, and Gemini CLI is ready.

See pricing

Frequently asked questions

Can you really code on an Android phone in 2026?

Yes, and more comfortably than most people expect. Android is the one mobile OS that lets a real Linux terminal run on-device: Termux installs a full APT package set with Bash, Python, Node.js, Git, and SSH, no rooting required. The honest constraints are an ARM (aarch64) userland that trips up a long tail of x86-only binaries, and the Android 12+ phantom-process killer that can end long-running jobs. The four real coding paths are Termux on-device, SSH from an app like Termius or ConnectBot to your own machine, a browser IDE like vscode.dev or GitHub Codespaces in Chrome, or a native cloud terminal app like Cosyra that runs a real x86_64 Ubuntu container.

Can you run Claude Code or other AI agents on Android?

Yes. On Termux, Claude Code installs via npm (pkg install nodejs git, then npm install -g @anthropic-ai/claude-code) plus a shell alias, because the npm package no longer ships a global CLI entry point. The official native installer does not work on Termux: the binary is linked against glibc while Termux uses Android's Bionic libc, and Anthropic closed the android-arm64 request as not planned. Codex CLI, OpenCode, and Gemini CLI are Node or Python CLIs that install the same way with similar caveats — OpenCode in particular trips a launcher misdetection bug on Termux, which we break down in running OpenCode on Android. We pre-install all four in the Cosyra container so on Android you skip the workarounds entirely.

Why does Termux keep crashing with "signal 9" on my phone?

That is the Android phantom-process killer. On Android 12 and later the OS kills background processes once a single app spawns more than 32 of them, or any process using heavy CPU, and Termux surfaces it as [Process completed (signal 9) - press Enter]. On Android 14+ you can disable it under Developer Options with "Disable child process restrictions"; earlier versions need an ADB or root workaround. A cloud container sidesteps the problem because the process runs on a Linux host, not under Android's process governor. We wrote the full fix in the Termux signal 9 guide.

Can you run a full Ubuntu or Debian on Android?

Locally, through a chroot. Termux plus proot-distro installs a glibc Ubuntu, Debian, Alpine, or Arch userland inside a PRoot sandbox, and the older UserLAnd app wraps the same idea in a wizard. Both still share the Android ARM kernel, so there is no systemd and no real Docker daemon. For a genuine x86_64 Ubuntu with apt working normally, you run it off-device — a remote Linux box over SSH, or a hosted container. Our Linux container on Android guide compares all three.

Can you run Docker on Android?

Not in any practical way on-device. Termux and proot-distro share the Android kernel and cannot run a real Docker daemon; emulated approaches need a QEMU VM and several gigabytes of free space for a setup the phantom killer tends to end. If your workflow needs containers, run them on a remote Linux host you SSH into, or a hosted Linux environment — noting that even hosted containers vary in what nested workloads they allow, so verify Docker-in-Docker case by case.

Can you run VS Code on Android?

Only in the browser. Microsoft ships no native Android VS Code app, so the path is opening vscode.dev or github.dev in Chrome. The browser sandbox has no integrated terminal or debugger, so you can edit and commit but you cannot run the code without a backend. To actually execute, you point that editor at a remote machine or pair it with a real terminal. Our Cosyra vs VS Code for the Web guide covers the gap.

Is an Android phone good enough to replace a laptop for coding?

For agent-driven and remote work, increasingly yes; for local native toolchains, no. If your day is writing prompts, reviewing diffs, running tests on a remote box, and pushing git, an Android phone with a Bluetooth keyboard plus either Termux or a cloud container covers it. If you depend on local Docker, GPU work, or a desktop IDE with no web build, the phone stays a second screen that handles the agent-shaped half of the job. See pricing for what the cloud container costs.