Terminal & SSH on Android: Complete Guide
Learn how to use PocketCode's built-in terminal — a local BusyBox shell plus an SSH client with SFTP and port forwarding — for scripting and remote servers.
Terminal & SSH on Android
One of PocketCode's most powerful tools is its integrated terminal: a
local shell (BusyBox ash) for scripting, plus an SSH client with SFTP for remote
servers. The Connections screen also has Serial and VNC/RDP panels, but they do
not work in this build (VNC/RDP connect without drawing a desktop), and there is
no Telnet screen.
SSH: Your server in your pocket
Quick setup
SSH connections are managed from PocketCode's Connections screen, not typed as a shell command. You add a host, choose password or key authentication, and the app handles the rest:
- Generate an Ed25519, RSA or ECDSA key (or a device-bound key held in the Android Keystore) in the in-app key manager, or import an existing one.
- Add its public key to your server's
~/.ssh/authorized_keysas usual. - Save the connection as a favorite and connect with a single tap.
No ssh/ssh-keygen command line to memorize — key generation, hosts and
port-forwarding rules all live in the SSH UI.
SSH Features
- Authentication: password, key pair (Ed25519, RSA, ECDSA) or keyboard-interactive
- Port forwarding: local and remote rules to reach remote services (the dynamic SOCKS option is not a real SOCKS proxy)
- Built-in SFTP: browse, create folders, rename and delete without leaving the app
- Multi-session: multiple simultaneous connections (Pro; Free runs one at a time)
- Keep-alive: packets every 30 seconds to keep an idle session open
Example: Deploy from your phone
Once you connect to a server from the Connections screen, you get a real remote shell — whatever tools are installed on that server are at your fingertips:
# You're now on the remote server over SSH
cd /var/www/myapp
git pull origin main
npm install --production
pm2 restart all
# Verify everything works
pm2 status
curl -s localhost:3000/health | jq .Those commands run on the remote machine, not on your phone — the deploy toolchain lives on the server you connected to.
The local shell
The local terminal is a real POSIX shell — BusyBox 1.34.1 ash (falling back
to Android's sh) — scoped to your project workspace (it runs with the app's own
permissions: it is not a sandbox). It ships with the standard Unix toolbox
(373 BusyBox applets), no extra installs needed:
# Coreutils and text tools are built in
ls -la
grep -rn "TODO" .
cat data.json | sed 's/old/new/g' > out.json
find . -name "*.log" | xargs tar czf logs.tgzIt's ideal for file wrangling, shell scripting, chaining tools with pipes, and prepping a project before a commit — all on the device.
Running code: use the editor's Run button
node is on the shell's PATH (node file.js, without native add-ons), but npm
and npx are not bundled, and there is no python or go command. Instead,
PocketCode runs code through the editor's Run button, backed by on-device
runtimes: JavaScript and TypeScript on the bundled Node.js, C with TCC, Python,
Ruby and PHP as WebAssembly runtimes, a limited Java interpreter and Kotlin, with
Lua, Go and Rhai as optional packs. Open a file, tap Run, and the output
streams to the console. See
Run code in 16 languages for the full
picture.
Productivity tips
1. Useful aliases
Keep your frequent shell commands short with the terminal's alias manager:
alias ll="ls -la"
alias gl="grep -rn"
alias h="cat *.log | tail -n 50"(Git operations run through PocketCode's built-in Git UI, and deploys through the
SSH connection to your server — not a local git/ssh binary.)
2. Port forwarding to reach remote services
Need to reach a database or service that only listens on the remote host? Add a
port-forwarding rule to the SSH connection in the Connections
screen (Free includes one) — e.g. forward the server's 5432 to a local port. Once the tunnel is up,
point PocketCode's database module at that local port to
browse and query the remote PostgreSQL, all through the encrypted SSH session.
3. File transfer with SFTP
The built-in SFTP explorer lets you:
- Browse the server filesystem, create folders, and rename or delete items (also in batches)
- See your phone and the server side by side in a dual-pane view (copying by dragging between the panes does not work yet)
- Send a file from the phone to the remote session with Attach file, which
uploads it to
/tmp
Downloading, and editing remote files in the editor, are not available from the SFTP views in this version.
Terminal themes
There are 12 built-in terminal themes: five are free (PocketCode, PocketCode Dark, PocketCode Light, Dark and Light) and seven are Pro. Terminal split and broadcast input are Pro too.
Free vs Pro
| Feature | Free | Pro |
|---|---|---|
| SSH hosts | 1 | No plan cap |
| Simultaneous sessions | 1 | No plan cap |
| SFTP | ✅ | ✅ |
| Port forwarding | 1 | No plan cap |
| Local shell (BusyBox) | ✅ | ✅ |
| Terminal themes | 5 | 12 |
PocketCode's terminal lets you manage servers, deploy apps over SSH, and script locally — all from your Android device. To run code, pair it with the editor's on-device runtimes. Start free and work from anywhere.
Frequently asked questions
Can you use a Linux terminal on Android?
Yes. PocketCode has a built-in terminal — a local shell (BusyBox 1.34.1 ash, with 373 applets) and the standard Unix tools — plus an SSH client with SFTP and port forwarding for remote machines, all on the phone.
Is it a full Linux distribution?
No. The local shell is BusyBox ash (coreutils and tools like ls, grep, sed, awk, find and tar), scoped to your project workspace. It is great for scripting and driving remote servers, but it is not a full distro: there is no package manager, no git, no python and no ssh client in it.
Does it have SSH and SFTP?
Yes — an SSH client with password, key (RSA, Ed25519, ECDSA, or a key held in the Android Keystore) and keyboard-interactive authentication, an SFTP browser and port forwarding. File upload from the phone goes through Attach file, which sends to /tmp; dragging between the SFTP panes does not copy yet. Serial and VNC/RDP panels exist in the Connections screen but do not work in this build, and there is no Telnet screen.
Can you run Python or Node in the terminal?
node is on the shell PATH, so you can run it from the terminal; npm and npx are not bundled. Python and the other languages run from the editor's Run button, backed by on-device runtimes. The terminal is for shell scripting and connecting to remote machines.
Does the terminal work offline?
The local shell runs on the device. The app needs a connection to sign in; opening it with a session already started works offline, and after that the shell works locally. SSH needs a network only because it reaches a remote server.
Terminal & SSH
Quick answers on this
Keep reading
- TutorialJuiceSSH alternatives for Android: what to use now that it has left Google PlayJuiceSSH left Google Play in December 2025. What happened, and when to pick Termius, ConnectBot, Termux or PocketCode, with the limits of each.7 min
- TutorialTermux alternatives for Android in 2026: what each one is actually forTermux is still the best Linux command line on Android. If you need a distro, a code editor, VS Code or a ready-made IDE, these are the honest alternatives.7 min
- TutorialDebugging JavaScript on Android: Breakpoints, Stepping and the Call StackDebug Node.js code on your Android phone: breakpoints, conditions and logpoints, stepping, variables, the call stack and Hot Reload — and what it does not do yet.3 min

