Skip to content

TUI Apps on Phone: tmux, vim, htop, Claude Code

By Cosyra Editorial Team

Published Last updated 10 min read

Short answer. You can run TUI apps on a phone if the terminal is real enough. tmux, vim, neovim, htop, lazygit, Claude Code, Codex CLI, OpenCode, and Gemini CLI need alternate-screen rendering, modifier keys, arrow keys, copy/paste, and persistent processes. Local terminals like Termux work well on Android for many tools; SSH clients work if you already have a server; browser IDE terminal panels are cramped; a mobile cloud terminal like Cosyra gives you the cleanest phone-first TUI path because the apps run in Ubuntu while the phone stays a native terminal.

This guide is for the searches that do not quite say "AI coding agent" yet: "TUI on phone," "tmux on iPhone," "vim on Android," "terminal app for htop," "phone terminal for Claude Code," and "can I run terminal UI apps from my phone?" Those queries are category-level. The answer is not just "install an app." The answer is choosing where the terminal process lives.

tl;dr

Use Termux for local Android TUIs, Blink Shell plus SSH if you already run a server, and Cosyra if you want managed Ubuntu, native iOS and Android apps, pre-installed AI coding CLIs, and session persistence without owning the server.

Pricing · 1 hour free on signup, then a 10-hour, 7-day trial. No credit card.

What do TUI apps need from a phone terminal?

A TUI is only as good as the terminal underneath it. Many mobile apps can show a shell prompt; fewer handle the details that interactive terminal programs assume. The practical requirements are alternate screen support, accurate redraws, raw keyboard input, modifier keys, paste behavior that does not corrupt commands, and long-lived process state.

TUI requirement Why it matters Cosyra path
Alternate screen tmux, vim, htop, and agents redraw full-screen views Rendered in a native mobile terminal connected to Ubuntu
ESC, TAB, CTRL, ALT Modal editors and shells need keys missing from glass keyboards Toolbar exposes terminal keys on iOS and Android
Arrow keys Required for history, menus, completion UIs, and TUIs Toolbar shortcuts plus external keyboard support
Persistent process Agents and tmux sessions should survive app switches Process runs in cloud Ubuntu, not on the phone CPU
Package installs Developers need apt, npm, pip, git, gh, and custom tools Ubuntu 24.04 container with persistent storage
Network resilience Phones switch Wi-Fi, cellular, foreground, and background often Reconnects to the same container state

What are the options for running TUI apps on phone?

There are four real options: run the TUI locally on Android, run it locally on iOS with a constrained shell, SSH to your own machine, or use a mobile cloud terminal. Browser IDEs can include terminal panels, but their primary UI is usually a desktop IDE or app-builder surface, which makes them weaker for TUI-heavy work on a narrow phone.

1. Local Android terminal: Termux

Termux is the best-known local Android path. It is excellent for many TUIs: tmux, vim, htop, git, Python scripts, Node tools, and package-manager work. The tradeoff is that everything runs on the phone in an Android-flavored ARM userland. That is fine for local tinkering and offline work. It is rougher for x86_64 Linux assumptions and long-running AI agent sessions.

2. Local iOS shells: iSH and a-Shell

iSH and a-Shell give iPhone users local terminal-like environments. They are useful for learning, scripts, and lightweight tools. They are not the smooth path for modern AI coding CLIs or heavy Linux workflows. iOS sandboxing, emulation overhead, and package compatibility all show up quickly once the TUI needs a real x86_64 Linux environment.

3. SSH client plus your own server

Blink Shell, Prompt, Termius, JuiceSSH, and Termux-as-SSH-client can all drive TUIs well if the remote machine is solid. This is the power-user path. Run tmux on the server, use mosh if available, and the phone becomes a remote terminal. The cost is operational: keys, machine uptime, OS patches, network access, and keeping the host awake.

4. Mobile cloud terminal: Cosyra

Cosyra is the managed version of the SSH path. You do not bring a server. The app connects to your Ubuntu 24.04 container, where tmux, vim, git, gh, Claude Code, Codex CLI, OpenCode, and Gemini CLI can run. The phone handles rendering and input; the container handles the process lifecycle.

Want the managed TUI path? Install Cosyra, open the terminal, and run the same tools you would run on a Linux box.

How do you run tmux, vim, htop, and AI CLIs on Cosyra?

The commands are normal Ubuntu commands. The key difference is that they run in a container that persists between phone sessions. That means a short coffee-line session can start an agent, a train stop can review the diff, and a later desktop session can pick up the same repo.

cosyra, TUI apps from iPhone or Android

$ tmux new -s work

$ htop

$ vim src/server.ts

$ git status --short

$ export ANTHROPIC_API_KEY=sk-ant-...

$ claude

> Inspect this diff and find the smallest safe change.

Why do AI coding TUIs fit phones better than IDEs?

AI coding agents changed the mobile coding equation. Before agents, coding from a phone meant typing source code into a tiny editor. With agents, the phone workflow is prompt, wait, inspect, approve, and redirect. That maps to a terminal better than it maps to a desktop IDE compressed into mobile Safari.

A TUI agent takes the whole viewport, streams output line by line, asks permission in place, and leaves files in a real repo. It is closer to a chat plus shell than to manual editing. That is why we built Cosyra around the terminal primitive instead of a file-tree-first layout.

We tested this assumption on a Pixel 8 and an iPhone 14 in May 2026. tmux, vim, htop, lazygit, and Claude Code rendered cleanly in the alternate screen, redrew correctly after orientation changes, and survived two backgroundings each. Where the experience broke down was always the keyboard layer, not the TUI layer: glass keyboards do not give you ESC, CTRL, ALT, or arrow keys for free, which is why our toolbar exposes those keys and why we suggest a Bluetooth keyboard for long vim sessions even though most agent loops are fine without one. The TUIs themselves treat the container like any other Linux machine.

Which TUI-on-phone setup should you pick?

Pick by the constraint you cannot compromise on. If you need offline, pick a local terminal and accept compatibility limits. If you already run a secure, always-on server, use SSH and tmux. If you want the server included and the agents already installed, use a mobile cloud terminal.

Frequently asked questions

Can you run TUI apps on a phone?

Yes. Hacker News threads on coding from a phone consistently land in the same three buckets: a local Android terminal for offline work, an SSH client connected to a server you own, or a mobile cloud terminal that includes the Linux environment. Browser IDE terminal panes can work, but they are usually not the best phone-sized TUI surface.

Can I run tmux from iPhone or Android?

Yes. The long-standing Hacker News answer for iOS is Blink Shell hooked to a tmux session over mosh, and Termux runs tmux natively on Android. With Cosyra, tmux runs inside the Ubuntu container so the phone client reconnects to the same session instead of starting a new one each time the app is closed.

Can I run vim or neovim from my phone?

Yes. The "Vim ported to iOS" Hacker News thread is the canonical reference for the local-iOS path; iVim and a-Shell are the modern heirs. For full neovim with plugins, language servers, and clipboard integration, the cleaner path on a phone is a remote Linux environment reached over SSH or a mobile cloud terminal. Cosyra ships with vim, and neovim installs with one apt command in the Ubuntu container.

Do I need a Bluetooth keyboard for TUI apps?

Not for agent-driven work. Hacker News threads on iPad-as-workstation consistently note that a Bluetooth keyboard makes long vim sessions far more comfortable, but the same threads agree that short AI coding loops and terminal navigation are fine on the glass keyboard if the terminal exposes ESC, CTRL, ALT, and arrow keys. Cosyra's mobile toolbar covers those keys.

How do people run Claude Code as a TUI on a phone today?

The two documented patterns in 2026 are Termux + Tailscale + SSH to a machine that runs Claude Code, or a mobile cloud terminal that runs Claude Code in the cloud Linux environment directly. The former is more DIY and depends on a host you maintain; the latter is what Cosyra does by default with Claude Code, Codex CLI, OpenCode, and Gemini CLI pre-installed.

Where should I go next?

Read Cosyra vs Replit mobile for app-builder vs terminal-first tradeoffs, mobile coding terminal for the full local, SSH, cloud IDE, and cloud terminal map, and pricing if you want to skip straight to trying Cosyra.

Run the terminal UI in the cloud, not in a cramped browser pane. Cosyra gives you a managed Ubuntu terminal with AI coding CLIs pre-installed.

Claude Code on phone · Codex CLI on phone · Mobile coding terminal