Run a fully functional VS Code development environment on Android β no PC required.
π Check out our new project: github.com/skynetfc/Atlantia-Empire
- Overview
- System Requirements
- Prerequisites
- Installation
- Extensions
- Development Environments
- Background Operation
- External Access
- Features
- Example Projects
- Troubleshooting
- Performance Tips
- Storage Integration
- Security
- Resources
This guide provides a complete, production-ready setup for running VS Code inside Termux on Android devices. Whether you're coding on the go, learning new languages, or building full-stack applications β this setup delivers a professional-grade development experience directly from your mobile device.
Target: Android 10+ | Termux 0.118+ | Code-Server 4.x
| Component | Minimum | Recommended |
|---|---|---|
| Termux Base | 200 MB | 500 MB |
| Code-Server | 500 MB | 1.0 GB |
| Node.js Runtime | 100 MB | 200 MB |
| Python Environment | 50 MB | 100 MB |
| Build Toolchain | 300 MB | 500 MB |
| VS Code Extensions | 100 MB | 300 MB |
| Project Workspace | 500 MB | 2.0 GB |
| Total | ~1.75 GB | ~4.6 GB |
β οΈ Recommendation: Maintain at least 5 GB of free storage for optimal performance and future expansion.
| Specification | Minimum | Recommended |
|---|---|---|
| RAM | 3 GB | 6 GB+ |
| Android Version | 10 (API 29) | 13+ (API 33+) |
| Processor | ARM64 | ARM64 (8-core) |
| Free Storage | 3 GB | 5 GB |
-
Install Termux from F-Droid
β οΈ Do not use the Google Play Store version β it is outdated and no longer maintained.- Download F-Droid: https://f-droid.org/
- Search for and install Termux
-
Install Termux:API (optional, recommended for extended functionality)
- Available on F-Droid alongside Termux
Ensure your package index and installed packages are current:
pkg update && pkg upgrade -yπΎ Storage impact: ~50β100 MB
Install the core toolchain required for development:
pkg install -y nodejs python git wget curl build-essentialπΎ Storage impact: ~400β600 MB
Installed components:
nodejsβ JavaScript runtime & npmpythonβ Python 3 interpreter & pipgitβ Version controlwget/curlβ Network utilitiesbuild-essentialβ GCC, make, and compilation tools
Code-Server is the official open-source VS Code distribution for remote development, running entirely in the browser.
npm install -g code-servercurl -fsSL https://code-server.dev/install.sh | shπΎ Storage impact: ~500 MB β 1.0 GB
Create the configuration directory and file:
mkdir -p ~/.config/code-servercat > ~/.config/code-server/config.yaml << 'EOF'
bind-addr: 127.0.0.1:8080
auth: password
password: CHANGE_THIS_TO_A_STRONG_PASSWORD
cert: false
EOFπ Security: Replace
CHANGE_THIS_TO_A_STRONG_PASSWORDwith a cryptographically strong password (16+ characters, mixed case, numbers, symbols).
Configuration reference:
| Key | Value | Description |
|---|---|---|
bind-addr |
127.0.0.1:8080 |
Localhost binding (secure default) |
auth |
password |
Password-based authentication |
password |
<your_password> |
Access credential |
cert |
false |
TLS disabled (use reverse proxy for HTTPS) |
Launch the server:
code-serverExpected output:
[2026-07-09T10:00:00.000Z] info code-server 4.95.3
[2026-07-09T10:00:00.000Z] info Using config file ~/.config/code-server/config.yaml
[2026-07-09T10:00:00.000Z] info HTTP server listening on http://127.0.0.1:8080/
[2026-07-09T10:00:00.000Z] info Session server listening on ~/.local/share/code-server/code-server-ipc.sock
- Open your preferred browser (Chrome, Firefox, Brave, etc.)
- Navigate to: http://127.0.0.1:8080
- Enter your configured password
- β VS Code is now running on your Android device
Install the following essential extensions via the Extensions panel (Ctrl+Shift+X):
| Extension | Publisher | Purpose |
|---|---|---|
| Python | Microsoft | Python language support, IntelliSense, debugging |
| ESLint | Microsoft | JavaScript/TypeScript linting |
| Prettier | Prettier | Code formatting |
| Live Server | Ritwick Dey | Local development server for web projects |
| C/C++ | Microsoft | C and C++ language support |
| Extension Pack for Java | Microsoft | Java development toolkit |
| GitLens | GitKraken | Enhanced Git visualization |
| Markdown All in One | Yu Zhang | Markdown authoring support |
πΎ Storage impact: ~10β50 MB per extension
pkg install python
pip install --upgrade pipπΎ Storage impact: ~50β100 MB
Verify installation:
python --version
pip --versionPre-installed with Step 2. Verify:
node --version # v22.x.x
npm --version # 10.x.xpkg install clangπΎ Storage impact: ~200β300 MB
Verify installation:
clang --versionpkg install openjdk-21πΎ Storage impact: ~300β400 MB
Verify installation:
java --version
javac --versionnpm install -g live-serverπΎ Storage impact: ~20β30 MB
To maintain VS Code availability without keeping Termux in the foreground, use one of the following methods:
Run code-server detached from the terminal:
nohup code-server > ~/code-server.log 2>&1 &Stop the server:
pkill code-serverView logs:
tail -f ~/code-server.log- Install Termux:Boot from F-Droid
- Create the boot directory:
mkdir -p ~/.termux/boot - Create the startup script:
cat > ~/.termux/boot/start-code-server.sh << 'EOF' #!/data/data/com.termux/files/usr/bin/bash termux-wake-lock nohup code-server > ~/code-server.log 2>&1 & EOF chmod +x ~/.termux/boot/start-code-server.sh
- Reboot your device β code-server starts automatically
pkg install tmuxCreate and attach to a session:
tmux new -s vscode
code-serverDetach: Ctrl+B then D
Reattach: tmux attach -t vscode
- Android Settings β Apps β Termux β Battery β Unrestricted
- Disable battery optimization for Termux
- Acquire wake lock to keep CPU active:
termux-wake-lock
- Release wake lock when done:
termux-wake-unlock
β Best Practice: Combine
nohup+termux-wake-lockfor maximum reliability.
To access VS Code from another device on the same local network:
-
Identify your device's IP address:
ifconfig
Look for the
wlan0interface (e.g.,192.168.1.42). -
Update the binding address:
nano ~/.config/code-server/config.yamlChange:
bind-addr: 0.0.0.0:8080
-
Restart code-server
-
Access from another device:
http://YOUR_DEVICE_IP:8080
β οΈ Security Warning: Only expose code-server on trusted local networks. For remote access, use a VPN or SSH tunnel.
| Capability | Status | Notes |
|---|---|---|
| Full VS Code Editor | β Supported | All editing features, multi-cursor, Emmet |
| Integrated Terminal | β Supported | Full bash/zsh access within editor |
| Git Integration | β Supported | Clone, commit, push, pull, diff |
| Extensions Marketplace | β Supported | Thousands of extensions available |
| Debugging | β Supported | Python, Node.js, C++, Java |
| IntelliSense | β Supported | Code completion, hover info, go-to-definition |
| File Explorer | β Supported | Full filesystem navigation |
| Multi-language Support | β Supported | 50+ programming languages |
| Remote Development | β Supported | Access from any browser on the network |
| Themes & Customization | β Supported | Full theme and settings sync |
mkdir -p ~/projects/flask-demo
cd ~/projects/flask-demo
pip install flaskapp.py:
from flask import Flask, jsonify
app = Flask(__name__)
@app.route('/')
def index():
return jsonify({
"message": "Hello from Termux VS Code!",
"platform": "Android",
"runtime": "Flask + Python"
})
@app.route('/health')
def health():
return jsonify({"status": "healthy"})
if __name__ == '__main__':
app.run(host='0.0.0.0', port=5000, debug=True)Run:
python app.pymkdir -p ~/projects/express-demo
cd ~/projects/express-demo
npm init -y
npm install expressserver.js:
const express = require('express');
const app = express();
app.use(express.json());
app.get('/', (req, res) => {
res.json({
message: 'Hello from Termux VS Code!',
platform: 'Android',
runtime: 'Node.js + Express'
});
});
app.get('/health', (req, res) => {
res.json({ status: 'healthy' });
});
app.listen(3000, '0.0.0.0', () => {
console.log('π Server running at http://0.0.0.0:3000');
});Run:
node server.jshello.cpp:
#include <iostream>
#include <string>
int main() {
std::string platform = "Termux on Android";
std::cout << "Hello from " << platform << "!" << std::endl;
std::cout << "Compiled with Clang in VS Code." << std::endl;
return 0;
}Compile and run:
clang++ -std=c++17 -O2 hello.cpp -o hello
./hello| Check | Command |
|---|---|
| Is code-server running? | pgrep -f code-server |
| Correct port? | cat ~/.config/code-server/config.yaml |
| Restart Termux | Close all sessions and reopen |
| Restart code-server | pkill code-server && code-server |
| Cause | Solution |
|---|---|
| No internet connection | Verify Wi-Fi / mobile data |
| ARM architecture limitation | Check extension compatibility |
| Outdated code-server | npm update -g code-server |
| Corrupted extension cache | rm -rf ~/.local/share/code-server/extensions |
# Clean package cache
pkg clean
# Remove unused dependencies
pkg autoremove -y
# Check code-server disk usage
du -sh ~/.config/code-server ~/.local/share/code-server
# List largest packages
dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -n | tail -20| Action | Command |
|---|---|
| Check available RAM | free -h |
| Kill all code-server processes | pkill -9 code-server |
| Update all packages | pkg update && pkg upgrade -y |
| Clear extension cache | rm -rf ~/.local/share/code-server/CachedExtensionVSIXs |
| Restart with minimal extensions | code-server --disable-extensions |
- Limit Open Tabs β Keep only actively edited files open
- Disable Unused Extensions β Uninstall or disable extensions not in use
- Use Lightweight Themes β Prefer Dark+ or Light+ over heavy custom themes
- Manage Terminal Instances β Close integrated terminals when not needed
- Regular Maintenance β Run
pkg cleanweekly to reclaim space - Enable File Exclusions β Add
node_modules/,__pycache__/tofiles.exclude - Reduce Editor Font Size β Smaller fonts improve rendering performance on mobile
Grant Termux access to Android shared storage:
termux-setup-storageAvailable mount points:
| Path | Description |
|---|---|
~/storage/downloads |
Downloads folder |
~/storage/dcim |
Camera photos & videos |
~/storage/shared |
Internal storage root |
~/storage/music |
Music directory |
~/storage/movies |
Movies directory |
~/storage/pictures |
Pictures directory |
Sync projects with Git:
cd ~/projects/my-app
git init
git add .
git commit -m "Initial commit"
git remote add origin https://github.com/username/repo.git
git push -u origin main| Practice | Implementation |
|---|---|
| Strong Authentication | Use 16+ character passwords with mixed entropy |
| Network Isolation | Bind to 127.0.0.1 by default; avoid 0.0.0.0 on public networks |
| Encrypted Remote Access | Use WireGuard or OpenVPN instead of direct exposure |
| Regular Updates | pkg upgrade weekly to patch vulnerabilities |
| Minimal Permissions | Grant only required Android permissions to Termux |
| Secret Management | Never commit credentials; use .env files excluded from Git |
| Session Timeout | Restart code-server after extended idle periods |
| Resource | Link |
|---|---|
| Code-Server Documentation | coder.com/docs/code-server |
| Termux Wiki | wiki.termux.com |
| VS Code Docs | code.visualstudio.com/docs |
| F-Droid Repository | f-droid.org |
| Atlantia Empire Project | github.com/skynetfc/Atlantia-Empire |
π‘ Note: This setup is ideal for mobile development, learning, prototyping, and lightweight production workloads. For resource-intensive tasks (large builds, heavy ML training), a dedicated workstation remains recommended.
If this guide helped you, please β star the repository!