A comprehensive, safety-focused setup guide for Termux with modern tools and best practices
π₯ Download: F-Droid | GitHub Releases
READ BEFORE PROCEEDING:
- NEVER run
rm -rf $PREFIXorrm -rf /data/data/com.termux/files/home /data/data/com.termux/files/usrunless you want to completely destroy your Termux installation (see Removal Commands for context) - ALWAYS have backups before running removal/cleanup commands
- Test commands individually before combining them into scripts
- The
exitcommands after every operation will close Termux - remove them if you want to continue working - Security tools are for authorized testing ONLY - illegal use carries serious legal consequences
- Stable: 0.118.3 (May 2025) - Recommended for most users
- Beta: 0.119.0-beta.3 (May-June 2025) - For testing new features
- Google Play: googleplay.2026.01.07 - NOT RECOMMENDED (heavily restricted to comply with Play Store policies)
Package Mirrors (2025-2026):
- Modern default mirrors: Cloudflare and Hetzner (more stable than older mirrors)
- Bootstrap files: Now tagged as
bootstrap-2026.01.11-r1and newer termux-change-repostill works but many users already on best mirrors by default- Recommended mirror for India/Asia: Cloudflare (usually fastest)
Package Availability Notes:
vlc- Available but heavy; most users prefermpv+ffmpegcombinationgdrive-downloader- May be fromtur-repo; availability varies by mirrortermux-api- IMPORTANT: Install both the F-Droid app AND runpkg install termux-apiopenjdk-17- Main supported Java version (openjdk-21 exists but less tested)tur-repo- Can break compatibility; only enable when you need specific packages
GUI/Desktop Changes:
- Modern approach (2026): Termux:X11 + proot-distro (better performance than VNC)
- Traditional approach: TigerVNC + XFCE (still works, but slower)
- See both methods in VNC Server Setup and Advanced Setup
Root/Swap File Limitation:
- Swap file creation requires root access (
swaponcommand) - Non-rooted devices: Swap commands will fail silently
- Android manages memory automatically on non-rooted devices
Configuration Backup Recommendation:
- Back up
~/.termux/termux.propertiesseparately (font & appearance settings) - Back up
~/.termux/colors.propertiesseparately (color schemes) - These survive
pkg upgradebut not full system restore
Version Managers (2026 Recommendation):
- For Python: Use
uvormise/asdfinstead of installing multiple versions directly - For Node.js: Use
nvmormise/asdf - Cleaner version management and easier switching
- Core Package Installation
- Python Tools & Media Utilities
- Optional Packages
- Package Managers Explained
- Common Use Cases
- Web Development
- Python Environment
- Git Workflow
- SSH Server Setup
- Database Setup
- Code Compilation
- Termux:Boot Setup
- VNC Server Setup
- Proot-Distro Ubuntu
- Desktop Environment
- QEMU Support
- Security Best Practices
- SSH Keys
- File Encryption
- Password Management
- Security Tools
- Official Resources
- GitHub Repositories
- Community & Support
- Related Apps
- Learning Resources
- Quick Links Reference
Termux is a powerful terminal emulator and Linux environment for Android that works without root. It combines:
- A full Linux command-line interface
- Extensive package collection (via APT/pkg)
- Development tools (Python, Node.js, Ruby, Go, Rust, etc.)
- Network utilities and servers
- Access to Android APIs
Key Features:
- β No root required
- β 2000+ packages available
- β Full Python, Node.js, Git support
- β SSH client/server
- β Access Android hardware (camera, GPS, sensors)
- β Run Linux distributions (Ubuntu, Debian, Arch)
Download Termux from F-Droid:
- Install F-Droid app store
- Search for "Termux" in F-Droid
- Install Termux (main app)
- Optionally install add-ons:
- Termux:API
- Termux:Boot
- Termux:Float
- Termux:Styling
- Termux:Widget
- Termux:Tasker
Direct Download:
- F-Droid: https://f-droid.org/packages/com.termux/
- GitHub Releases: https://github.com/termux/termux-app/releases
The Play Store version of Termux is outdated and abandoned. It will not receive updates and may have compatibility issues.
Absolute minimum setup for most users:
# Enable storage & update system
termux-setup-storage
pkg update && pkg upgrade -y
# Install essential tools
pkg install -y python git neovim ffmpeg proot-distro nodejs wget curl
# Install yt-dlp
pip install -U yt-dlp
# Done! Start using TermuxOne-liner for power users:
termux-setup-storage && pkg update && pkg upgrade -y && pkg install -y python git neovim ffmpeg mpv yt-dlp proot-distro nodejs openjdk-17 wget curl gh nmap termux-api && pip install -U yt-dlp && pkg autocleantermux-setup-storageThis grants Termux permission to access your device's shared storage.
# Change to faster mirror (optional - most users already on good mirrors)
termux-change-repo
# Recommended: Select Cloudflare mirror (fastest in most regions, especially India/Asia)
# Note: Hetzner and default mirrors are also stable in 2026
# Update package lists
pkg update
# Add additional repositories
pkg install root-repo x11-repo tur-repo -y
# β οΈ Note: tur-repo can occasionally break compatibility
# Only keep it enabled if you need specific packages from it
# Full system update
pkg update && pkg upgrade -y
# Initial cleanup
apt clean && pkg clean && pkg autocleanRepository Notes (January 2026):
- Cloudflare mirror: Best for India, Asia, and most global locations
- Hetzner mirror: Good European alternative
- tur-repo warning: User-maintained packages may have compatibility issues. Disable after installing needed packages:
# To disable tur-repo after use: pkg uninstall tur-repo
Note: Remove the && exit from the original if you want to continue without closing Termux.
pkg install -y \
7zip mount-utils exfatprogs e2fsprogs \
python gnupg python-pip \
proot-distro proot fakeroot busybox \
ruby openjdk-17 \
mpv neovim ffmpeg ytui-music sox vlc \
git iproute2 android-tools tsu neofetch \
wget cmake make curl gh parted bash \
nmap termux-api gdrive-downloader \
nodejs rust
# Cleanup
apt clean && pkg clean && pkg autoclean && apt autoremove -yPackage Categories:
- Compression: 7zip
- Filesystem: mount-utils, exfatprogs, e2fsprogs
- Languages: python, ruby, nodejs, rust, openjdk-17
- Media: mpv, ffmpeg, ytui-music, sox, vlc
- Development: git, neovim, cmake, make, curl, gh
- System: proot-distro, tsu, nmap, termux-api
-
vlc- Heavy package (~200MB). Most users prefermpv+ffmpegwhich are lighter and faster# Lightweight alternative: Skip VLC, use mpv only pkg install mpv ffmpeg -y -
gdrive-downloader- May be unavailable on some mirrors; primarily intur-repo# If not found, ensure tur-repo is enabled pkg install tur-repo pkg update pkg install gdrive-downloader -
termux-api- CRITICAL: You need BOTH:- Install Termux:API app from F-Droid: https://f-droid.org/packages/com.termux.api/
- Install the package:
pkg install termux-api
Without the F-Droid app, termux-api commands won't work!
-
openjdk-17- Main supported Java version in Termuxopenjdk-21exists but is less tested- Stick with 17 unless you specifically need 21
-
Version Managers (Modern Approach 2026):
# Instead of installing multiple Python versions: pip install uv # Modern Python version manager # Or use mise (universal version manager) curl https://mise.run | sh mise install python@3.11 python@3.12 # For Node.js version management: curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.0/install.sh | bash
Option 1: Stable Release
pip install yt-dlpOption 2: Latest Pre-release (Recommended)
pip install -U --pre "yt-dlp[default]"# Install yturl
pip install yturl
# Modern Python package managers
pip install pipx pip-tools
pipx install uv# Convert WebM to MP3
ffmpeg -i input.webm -vn -ar 44100 -ac 2 -b:a 192k output.mp3Parameters explained:
-vn- No video-ar 44100- Audio sample rate-ac 2- Audio channels (stereo)-b:a 192k- Audio bitrate
These packages provide advanced functionality but aren't required for basic use:
pkg install -y \
iproute2 bash-completion perl \
mount-utils autoconf automake \
bison flex libtool m4 pcre \
silversearcher-ag apache2 apr apr-util \
fish libxslt python-lxml python-tkinter
# Cleanup
pkg update -y && pkg upgrade -y
apt clean && pkg clean && pkg autoclean && apt autoremove -yUse cases:
- Development: autoconf, automake, libtool
- Shells: fish (modern shell alternative)
- Web: apache2 (web server)
- Search: silversearcher-ag (fast code search)
Basic port scanning:
# Scan common ports on a host
nmap example.com
# Scan specific ports
nmap -p 80,443,8080 example.com
# Scan port range
nmap -p 1-1000 example.com
# Fast scan (top 100 ports)
nmap -F example.com
# Service version detection
nmap -sV example.com
# OS detection (requires root)
nmap -O example.com# Check your IP address
curl ifconfig.me
# or
curl icanhazip.com
# DNS lookup
nslookup example.com
# Trace route to host
traceroute example.com
# Check open ports on your device
netstat -tuln
# Monitor network connections
ss -tuln
# Check network interfaces
ip addr show
# Ping a host
ping -c 4 google.com
# Check WiFi information
termux-wifi-connectioninfo# Install speedtest-cli
pip install speedtest-cli
# Run speed test
speedtest-cli
# Simple version
speedtest-cli --simple# Download file with wget
wget https://example.com/file.zip
# Download with progress bar
wget --progress=bar https://example.com/file.zip
# Resume interrupted download
wget -c https://example.com/file.zip
# Download with curl
curl -O https://example.com/file.zip
# Download and save with different name
curl -o myfile.zip https://example.com/file.zipYou need BOTH components:
- Termux:API app from F-Droid: https://f-droid.org/packages/com.termux.api/
- termux-api package:
pkg install termux-api
Without both installed, API commands will fail silently or show "command not found"!
# Check if package is installed
pkg list-installed | grep termux-api
# Test if API app is working
termux-battery-status
# Should return JSON with battery info# Take a photo (saves to ~/storage/dcim/)
termux-camera-photo ~/storage/dcim/photo.jpg
# Take photo with front camera
termux-camera-photo -c 1 ~/storage/dcim/selfie.jpg# Get battery status
termux-battery-status
# Pretty print battery info
termux-battery-status | python -m json.tool# Get current location (GPS)
termux-location
# Get location with specific provider
termux-location -p gps
# Get location with network provider
termux-location -p network# Send notification
termux-notification -t "Title" -c "Content message"
# Notification with action
termux-notification -t "Download Complete" -c "File.zip ready" --sound
# Vibrate notification (still works in 2026)
termux-notification -t "Alert" -c "Check this!" --vibrate 200,100,200# Send SMS
termux-sms-send -n "+1234567890" "Hello from Termux!"
# List SMS messages
termux-sms-list
# List only inbox
termux-sms-list -t inbox -l 10# Copy to clipboard
echo "Hello World" | termux-clipboard-set
# Get clipboard content
termux-clipboard-get# Vibrate for 1 second
termux-vibrate -d 1000
# Vibrate pattern (on,off,on,off in ms)
termux-vibrate -d 500,200,500# Show toast message
termux-toast "Hello from Termux!"
# Short duration toast
termux-toast -s "Quick message"
# Long duration toast
termux-toast -l "Longer message display"# Get current volume
termux-volume
# Set music volume to 50%
termux-volume music 50
# Set alarm volume to max
termux-volume alarm 15# Turn on flashlight
termux-torch on
# Turn off flashlight
termux-torch off# List all contacts
termux-contact-list
# Get specific contact
termux-contact-list | grep "John"# Get recent calls
termux-call-log
# Get last 5 calls
termux-call-log -l 5 -o all# Screen brightness control
termux-brightness 100 # Max brightness
# Microphone recording
termux-microphone-record -f output.mp3
# TTS (Text-to-Speech)
termux-tts-speak "Hello from Termux"
# Download with notification
termux-download https://example.com/file.zip
# Sensor data
termux-sensor -s light
termux-sensor -s accelerometer
# WiFi information
termux-wifi-connectioninfo
termux-wifi-scaninfoAfter running termux-setup-storage, you'll have these shortcuts:
# Navigate to common directories
cd ~/storage/shared # Internal storage
cd ~/storage/downloads # Downloads folder
cd ~/storage/dcim # Camera photos
cd ~/storage/pictures # Pictures folder
cd ~/storage/music # Music folder
cd ~/storage/movies # Videos folder# Link Downloads to home directory
ln -s ~/storage/downloads ~/downloads
# Link DCIM for easy photo access
ln -s ~/storage/dcim ~/photos
# Link Music folder
ln -s ~/storage/music ~/music
# Create custom shortcuts
ln -s ~/storage/shared/MyFiles ~/files# Copy files to Android storage
cp myfile.txt ~/storage/downloads/
# Move files
mv myfile.txt ~/storage/documents/
# Create directory in shared storage
mkdir -p ~/storage/shared/MyProjects
# Archive and move to storage
tar -czf project.tar.gz myproject/
mv project.tar.gz ~/storage/downloads/# Make a file accessible to Android apps
cp document.pdf ~/storage/downloads/
# Access file shared by Android app
cat ~/storage/downloads/shared-file.txt
# Edit file with Android editor, then process in Termux
vim ~/storage/downloads/document.txt# Find files by name
find ~/storage/shared -name "*.pdf"
# Find files modified in last 7 days
find ~/storage/downloads -mtime -7
# Search for text in files
grep -r "search term" ~/storage/documents/
# Get file size
du -h filename
# Get directory size
du -sh ~/storage/downloads/
# List files by size
ls -lhS
# List files by modification time
ls -lht# β οΈ This section requires root/tsu access
# On non-rooted devices, these commands will fail silently
# Create 1GB swap file (requires root)
fallocate -l 1G $PREFIX/var/swapfile
chmod 600 $PREFIX/var/swapfile
mkswap $PREFIX/var/swapfile
# Enable swap (requires root - will fail without root)
swapon $PREFIX/var/swapfile
# Check swap status
free -h
# To disable swap
swapoff $PREFIX/var/swapfileImportant Notes:
- β With root: Swap can help on low-RAM devices (but may wear out storage)
- β Without root: Android manages memory automatically; swap commands will fail
- π‘ Alternative: Close background apps, use lighter packages, disable unused services
Non-Root Memory Optimization:
# Use lighter alternatives
pkg install busybox # Lighter than full coreutils
pkg install micro # Lighter than vim if you don't need all features
# Monitor memory without swap
free -h
top
# Kill memory-heavy processes
pkill process-name# View running processes
top
# View processes (alternative)
htop # install with: pkg install htop
# Kill process by name
pkill process-name
# Kill process by PID
kill 12345
# Force kill process
kill -9 12345
# View all Termux processes
ps aux | grep termux
# Find resource-heavy processes
ps aux --sort=-%mem | head -10Disable battery optimization for Termux:
- Go to Android Settings
- Apps β Termux
- Battery β Battery optimization
- Select "All apps"
- Find Termux β Select "Don't optimize"
For Termux:API, Termux:Boot, Termux:Widget: Repeat the same process for each app.
# Check memory usage
free -h
# Clear system cache (limited effect)
sync
echo 3 > /proc/sys/vm/drop_caches # requires root
# View memory info
cat /proc/meminfo
# Monitor memory in real-time
watch -n 1 free -h# Use faster mirror
termux-change-repo
# Select mirror closest to your location
# Parallel downloads (experimental)
echo "Acquire::Queue-Mode \"access\";" >> $PREFIX/etc/apt/apt.conf.d/99customNode.js Server:
# Install Node.js
pkg install nodejs
# Create simple server
cat > server.js << 'EOF'
const http = require('http');
const server = http.createServer((req, res) => {
res.writeHead(200, {'Content-Type': 'text/html'});
res.end('<h1>Hello from Termux!</h1>');
});
server.listen(8080, () => {
console.log('Server running at http://localhost:8080/');
});
EOF
# Run server
node server.js
# Access from Android browser: http://localhost:8080Python Web Server:
# Simple HTTP server (Python 3)
python -m http.server 8000
# Access at: http://localhost:8000# Install Python tools
pkg install python python-pip
# Create virtual environment
pip install virtualenv
virtualenv myenv
source myenv/bin/activate
# Install common packages
pip install numpy pandas matplotlib requests flask
# Create requirements file
pip freeze > requirements.txt
# Deactivate environment
deactivateInitial Setup:
# Configure Git
git config --global user.name "Your Name"
git config --global user.email "your@email.com"
# Set default editor
git config --global core.editor "vim"
# Cache credentials (1 hour)
git config --global credential.helper 'cache --timeout=3600'Common Commands:
# Clone repository
git clone https://github.com/user/repo.git
# Check status
git status
# Add and commit
git add .
git commit -m "Update message"
# Push changes
git push origin main
# Pull latest changes
git pull
# Create new branch
git checkout -b feature-branch
# View commit history
git log --oneline --graphGitHub CLI:
# Install GitHub CLI
pkg install gh
# Authenticate
gh auth login
# Create repository
gh repo create my-project --public
# Clone your repos
gh repo clone username/repository
# Create issue
gh issue create
# View pull requests
gh pr listRun SSH server in Termux:
# Install OpenSSH
pkg install openssh
# Set password for Termux
passwd
# Start SSH server
sshd
# Find your IP address
ip addr show wlan0 | grep inet
# Default port: 8022
# Connect from PC: ssh -p 8022 username@phone-ipSSH Client (Connect to other servers):
# Connect to remote server
ssh user@hostname
# Connect with specific key
ssh -i ~/.ssh/id_rsa user@hostname
# Copy files to remote server
scp file.txt user@hostname:/path/to/destination/
# Copy files from remote server
scp user@hostname:/path/to/file.txt ./C/C++ Development:
# Install compiler
pkg install clang
# Compile C program
clang program.c -o program
# Compile C++ program
clang++ program.cpp -o program
# Run
./programRust Development:
# Install Rust
pkg install rust
# Create new project
cargo new myproject
cd myproject
# Build project
cargo build
# Run project
cargo runSQLite:
# Install SQLite
pkg install sqlite
# Create database
sqlite3 mydb.db
# In SQLite prompt:
CREATE TABLE users (id INTEGER PRIMARY KEY, name TEXT);
INSERT INTO users VALUES (1, 'John');
SELECT * FROM users;
.quitPostgreSQL:
# Install PostgreSQL
pkg install postgresql
# Initialize database
mkdir -p $PREFIX/var/lib/postgresql
initdb $PREFIX/var/lib/postgresql
# Start server
pg_ctl -D $PREFIX/var/lib/postgresql start
# Create database
createdb mydb
# Connect
psql mydbBoth pkg and apt work in Termux, but pkg is recommended:
pkg (Recommended):
pkg install package-name # Install package
pkg update # Update package lists
pkg upgrade # Upgrade packages
pkg search keyword # Search for packages
pkg show package-name # Show package info
pkg list-installed # List installed packages
pkg uninstall package-name # Remove package
pkg files package-name # List files in packageapt (Advanced):
apt update # Update package lists
apt upgrade # Upgrade packages
apt install package-name # Install package
apt remove package-name # Remove package
apt autoremove # Remove unused dependencies
apt clean # Clear cache
apt search keyword # Search packages
apt show package-name # Package detailsKey Differences:
pkgis a wrapper aroundaptwith better defaultspkgautomatically runsapt updatewhen neededpkghas shorter, more intuitive commands- Both can be used interchangeably for most operations
# Install Python package
pip install package-name
# Install specific version
pip install package-name==1.2.3
# Upgrade package
pip install --upgrade package-name
# Uninstall package
pip uninstall package-name
# List installed packages
pip list
# Show package info
pip show package-name
# Search for packages
pip search keyword # (deprecated, use PyPI website)
# Install from requirements file
pip install -r requirements.txt
# Generate requirements file
pip freeze > requirements.txt# Install package globally
npm install -g package-name
# Install package locally
npm install package-name
# Install dev dependency
npm install --save-dev package-name
# Uninstall package
npm uninstall package-name
# Update packages
npm update
# List installed packages
npm list
# Check for outdated packages
npm outdatedRun scripts automatically when your device boots.
# Install from F-Droid: Termux:Boot app
# Create boot scripts directory
mkdir -p ~/.termux/boot# Example: Start SSH server on boot
cat > ~/.termux/boot/start-sshd << 'EOF'
#!/data/data/com.termux/files/usr/bin/sh
termux-wake-lock
sshd
EOF
# Make executable
chmod +x ~/.termux/boot/start-sshdStart Syncthing on boot:
cat > ~/.termux/boot/start-syncthing << 'EOF'
#!/data/data/com.termux/files/usr/bin/sh
termux-wake-lock
syncthing -no-browser &
EOF
chmod +x ~/.termux/boot/start-syncthingRun backup script on boot:
cat > ~/.termux/boot/backup << 'EOF'
#!/data/data/com.termux/files/usr/bin/sh
sleep 60 # Wait for system to fully boot
tar -czf ~/storage/downloads/auto-backup-$(date +%Y%m%d).tar.gz ~/important-files/
EOF
chmod +x ~/.termux/boot/backupTest boot scripts:
# Run manually to test
~/.termux/boot/start-sshdTermux:X11 provides better performance than VNC for GUI applications.
Installation:
# Install Termux:X11 app from GitHub
# Download: https://github.com/termux/termux-x11/releases
# Install the APK manually
# Install required packages in Termux
pkg install x11-repo
pkg install termux-x11-nightly
pkg install pulseaudioUsing with Proot-Distro:
# Install a Linux distribution
proot-distro install ubuntu
# Install desktop environment in proot
proot-distro login ubuntu
# Inside Ubuntu:
apt update
apt install xfce4 xfce4-goodies dbus-x11 -y
exit
# Start Termux:X11 and desktop
termux-x11 :0 &
pulseaudio --start --load="module-native-protocol-tcp auth-ip-acl=127.0.0.1 auth-anonymous=1" --exit-idle-time=-1
proot-distro login ubuntu --shared-tmp -- bash -c "export DISPLAY=:0 PULSE_SERVER=127.0.0.1; dbus-launch --exit-with-session startxfce4"Advantages of Termux:X11:
- β Better performance than VNC
- β Hardware acceleration support
- β Lower latency
- β Direct window integration
VNC is still useful for remote access or if Termux:X11 doesn't work on your device.
# Install TigerVNC
pkg install tigervnc
# Install desktop environment (choose one)
pkg install xfce4 # Recommended - lightweight
# or
pkg install lxde # Very lightweight
# or
pkg install openbox # Minimal# Set VNC password
vncserver
# This creates ~/.vnc directory and asks for password
# Enter a password (6-8 characters)# Start VNC server
vncserver -localhost
# Note the display number, usually :1Install VNC Viewer on Android:
- Install "VNC Viewer" from Play Store
- Create new connection:
- Address:
localhost:5901(5900 + display number) - Name: Termux VNC
- Address:
Start VNC:
cat > ~/start-vnc << 'EOF'
#!/data/data/com.termux/files/usr/bin/bash
vncserver -localhost -geometry 1920x1080 -depth 24
EOF
chmod +x ~/start-vncStop VNC:
cat > ~/stop-vnc << 'EOF'
#!/data/data/com.termux/files/usr/bin/bash
vncserver -kill :1
EOF
chmod +x ~/stop-vnc# Start VNC server
~/start-vnc
# Open VNC Viewer app on Android
# Connect to localhost:5901
# Stop VNC server when done
~/stop-vnc# Configure XFCE to start with VNC
cat > ~/.vnc/xstartup << 'EOF'
#!/data/data/com.termux/files/usr/bin/bash
export PULSE_SERVER=127.0.0.1
startxfce4 &
EOF
chmod +x ~/.vnc/xstartup
# Restart VNC server
vncserver -kill :1
vncserver -localhost -geometry 1920x1080# Check if VNC is running
ps aux | grep vnc
# View VNC log
cat ~/.vnc/*.log
# Kill all VNC sessions
vncserver -kill :*
# Change VNC resolution
vncserver -kill :1
vncserver -localhost -geometry 1280x720| Method | Performance | Remote Access | Setup Difficulty |
|---|---|---|---|
| Termux:X11 | β‘β‘β‘ Excellent | β Local only | π§ Medium |
| VNC | β‘β‘ Good | β Yes | π§ Easy |
| No GUI | β‘β‘β‘β‘ Best | β SSH | π§ Easy |
Recommendation: Use Termux:X11 for local GUI apps, VNC for remote access, or command-line for best performance.
Generate SSH Key:
# Generate new SSH key
ssh-keygen -t ed25519 -C "your@email.com"
# Or RSA (for compatibility)
ssh-keygen -t rsa -b 4096 -C "your@email.com"
# Save to: ~/.ssh/id_ed25519
# Set a strong passphraseCopy public key to server:
# View your public key
cat ~/.ssh/id_ed25519.pub
# Copy to remote server
ssh-copy-id -p 22 user@remote-server
# Or manually
cat ~/.ssh/id_ed25519.pub | ssh user@remote-server "mkdir -p ~/.ssh && cat >> ~/.ssh/authorized_keys"Configure SSH client:
# Create SSH config
cat > ~/.ssh/config << 'EOF'
Host myserver
HostName example.com
User username
Port 22
IdentityFile ~/.ssh/id_ed25519
Host github
HostName github.com
User git
IdentityFile ~/.ssh/id_ed25519
EOF
chmod 600 ~/.ssh/config
# Now you can connect with:
ssh myserverSet Termux password:
# Set password (for SSH access)
passwd
# Use strong password with:
# - Minimum 12 characters
# - Mix of uppercase, lowercase, numbers, symbolsDisable password login (SSH keys only):
# Edit sshd config
nano $PREFIX/etc/ssh/sshd_config
# Find and change:
PasswordAuthentication no
PermitRootLogin no
PubkeyAuthentication yes
# Restart SSH server
pkill sshd
sshdEncrypt files with GPG:
# Install GPG
pkg install gnupg
# Encrypt file
gpg -c secret.txt
# Enter passphrase
# Creates: secret.txt.gpg
# Decrypt file
gpg secret.txt.gpg
# Enter passphrase
# Creates: secret.txtEncrypt with password:
# Install openssl
pkg install openssl
# Encrypt file
openssl enc -aes-256-cbc -salt -in file.txt -out file.txt.enc
# Decrypt file
openssl enc -aes-256-cbc -d -in file.txt.enc -out file.txtUsing pass (Unix password manager):
# Install pass
pkg install pass
# Generate GPG key first
gpg --full-generate-key
# Initialize pass
pass init your@email.com
# Store password
pass insert email/gmail
pass insert social/facebook
# Retrieve password
pass email/gmail
# Generate random password
pass generate email/newaccount 20
# List all passwords
pass
# Remove password
pass rm email/oldaccountCheck open ports:
# List all open ports
netstat -tuln
# Or with ss
ss -tuln
# Check specific port
netstat -tuln | grep :8080Firewall (requires root):
# Note: Most users don't need this without root
# Android manages network permissions
# With root, you can use iptables
iptables -L# Make file readable only by you
chmod 600 sensitive-file.txt
# Make directory private
chmod 700 ~/private-directory/
# Check file permissions
ls -la filename
# Remove execute permission
chmod -x script.sh
# Add execute permission
chmod +x script.sh# Update all packages (security patches)
pkg update && pkg upgrade -y
# Remove old/unused packages
pkg autoremove -y
# Check for suspicious processes
ps aux
# View login attempts (if SSH server running)
cat $PREFIX/var/log/auth.log
# Check Termux app permissions in Android settings
# Remove unnecessary permissions# Create encrypted backup
tar -czf - ~/important-files/ | \
gpg -c > ~/storage/downloads/backup-$(date +%Y%m%d).tar.gz.gpg
# Restore encrypted backup
gpg -d ~/storage/downloads/backup-20260129.tar.gz.gpg | \
tar -xzf - -C ~/AVcleaner is a utility for removing/obfuscating antivirus signatures from APK files.
Use Cases:
- Testing AV detection capabilities (security research)
- Legitimate app development testing
- Bypassing false positives (rare cases)
- This is a controversial tool with potential for misuse
- Using it to distribute malware is illegal
- Only use for authorized security research or legitimate testing
- Most users will never need this tool
# Clone repository
git clone https://github.com/RedQueen979/AVcleaner
cd AVcleaner
# Make executable
chmod +x AVcleaner.sh
# Create system-wide command (optional)
ln -s ~/AVcleaner/AVcleaner.sh $PREFIX/bin/clean
# Return to home
cd ~clean # if you created the symlink
# or
~/AVcleaner/AVcleaner.shβ Don't use if you're just learning Termux
β Don't use for distributing any applications
β Don't use unless you understand APK structure and AV detection
β Don't use without legitimate security research purpose
Alternative: If you're getting false positives on your legitimate app, contact the AV vendor directly rather than obfuscating signatures.
cd ~/storage/shared
rm -rf termux-backup 2>/dev/null # Remove old backup if exists
mkdir termux-backup
cd ~# Backup both home and usr directories
tar -zcf ~/storage/shared/termux-backup/termux-backup-$(date +%Y%m%d).tar.gz \
-C /data/data/com.termux/files ./home ./usrBackup includes:
- All installed packages (
./usr) - Your home directory files (
./home) - Configuration files
These files survive pkg upgrade but NOT full restores, so back them up separately:
# Backup appearance settings
cp ~/.termux/termux.properties ~/storage/shared/termux-backup/termux.properties.backup
cp ~/.termux/colors.properties ~/storage/shared/termux-backup/colors.properties.backup
# Backup font (if custom)
cp ~/.termux/font.ttf ~/storage/shared/termux-backup/font.ttf.backup 2>/dev/null
# Backup shell configuration
cp ~/.bashrc ~/storage/shared/termux-backup/bashrc.backup
cp ~/.bash_profile ~/storage/shared/termux-backup/bash_profile.backup 2>/dev/null
# Backup important scripts
tar -czf ~/storage/shared/termux-backup/scripts-$(date +%Y%m%d).tar.gz \
~/.termux/boot/ ~/.shortcuts/ 2>/dev/null# Save this as ~/backup-all.sh
cat > ~/backup-all.sh << 'EOF'
#!/data/data/com.termux/files/usr/bin/bash
DATE=$(date +%Y%m%d_%H%M%S)
BACKUP_DIR=~/storage/shared/termux-backup
mkdir -p $BACKUP_DIR
echo "Creating full system backup..."
tar -zcf $BACKUP_DIR/termux-full-$DATE.tar.gz \
-C /data/data/com.termux/files ./home ./usr
echo "Backing up configuration files..."
mkdir -p $BACKUP_DIR/config-$DATE
cp ~/.termux/*.properties $BACKUP_DIR/config-$DATE/ 2>/dev/null
cp ~/.termux/*.ttf $BACKUP_DIR/config-$DATE/ 2>/dev/null
cp ~/.bashrc $BACKUP_DIR/config-$DATE/
cp ~/.bash_profile $BACKUP_DIR/config-$DATE/ 2>/dev/null
echo "Backing up boot scripts and shortcuts..."
tar -czf $BACKUP_DIR/scripts-$DATE.tar.gz \
~/.termux/boot/ ~/.shortcuts/ 2>/dev/null
echo "Backup completed: $BACKUP_DIR"
ls -lh $BACKUP_DIR/*$DATE*
EOF
chmod +x ~/backup-all.sh
# Run backup
~/backup-all.shFull System Restore:
# β οΈ WARNING: This will overwrite your current installation
tar -zxf ~/storage/shared/termux-backup/termux-backup-YYYYMMDD.tar.gz \
-C /data/data/com.termux/files \
--recursive-unlink \
--preserve-permissions
# Clear history after restore
cat /dev/null > ~/.bash_history && history -cRestore Configuration Only:
# Restore appearance settings
cp ~/storage/shared/termux-backup/termux.properties.backup ~/.termux/termux.properties
cp ~/storage/shared/termux-backup/colors.properties.backup ~/.termux/colors.properties
# Restart Termux to apply changes
exit
# Then reopen TermuxCreate daily backup with Termux:Boot:
mkdir -p ~/.termux/boot
cat > ~/.termux/boot/backup-daily << 'EOF'
#!/data/data/com.termux/files/usr/bin/sh
# Wait for system to settle
sleep 300 # 5 minutes
# Run backup
~/backup-all.sh
# Keep only last 7 days of backups
find ~/storage/shared/termux-backup/ -name "termux-full-*.tar.gz" -mtime +7 -delete
EOF
chmod +x ~/.termux/boot/backup-dailyRun a full Ubuntu environment inside Termux (no root required).
proot-distro install ubuntuInstallation location:
/data/data/com.termux/files/usr/var/lib/proot-distro/installed-rootfs/ubuntu/
proot-distro login ubuntu# Update Ubuntu packages
apt-get update -y && apt-get dist-upgrade -y
# Add universe repository
apt-get install software-properties-common -y
add-apt-repository universe
apt update && apt upgrade -y
# Install essential packages
apt-get install -y \
apt-utils cmake make libreadline-dev sudo 7zip \
mpv apt parted bash ca-certificates command-not-found \
coreutils curl debianutils dpkg gpgv less nano \
patch zstd sox vlc git iproute2 bash-completion \
wget perl neofetch pkg-config python3 synaptic
# Cleanup
apt upgrade -y
apt clean && apt autoremove -y# Install Cinnamon (Heavy - 2GB+ RAM recommended)
sudo apt install cinnamon-desktop-environment -y
# Install multimedia codecs
sudo apt install libavcodec-extra ubuntu-restricted-extras -y
# Alternative: XFCE (Lighter)
# sudo apt install xfce4 xfce4-goodies -yRequirements for GUI:
- Install Termux:X11 app (from GitHub, not Play Store)
- Or use VNC server (easier for beginners)
apt-get install qemu-system-aarch64 -y
pkg install qemu-utils -ycat /dev/null > ~/.bash_history && history -c
exitβ οΈ CLICK TO EXPAND - AUTHORIZED SECURITY TESTING ONLY β οΈ
READ THIS ENTIRE SECTION BEFORE PROCEEDING:
This section documents security testing tools that are ONLY for:
- β Authorized penetration testing with written permission
- β Educational purposes in controlled lab environments
- β Testing your own systems that you own
- β Certified security professional training
ILLEGAL USES - DO NOT:
- β Test any system without explicit written authorization
- β Use phishing tools against real people
- β Conduct unauthorized network scanning
- β Attempt to access systems you don't own
- β Distribute or use maliciously in any way
CONSEQUENCES OF MISUSE:
- Criminal charges under Computer Fraud and Abuse Act (CFAA)
- International cybercrime laws (equivalent in most countries)
- Civil lawsuits for damages
- Permanent criminal record
- Prison sentences (varies by jurisdiction)
2026 COMMUNITY STANDARDS: Many security communities now discourage publicly listing certain tools (especially phishing frameworks) in beginner guides due to widespread misuse. This section is included for completeness but with extreme warnings.
Only proceed if:
- You have written authorization from your employer/client
- You are conducting red-team exercises in a controlled environment
- You understand the full legal implications
Installation (Educational/Authorized Use Only):
# Install dependencies
pkg install git curl php openssh -y
# Clone repository
git clone https://github.com/htr-tech/zphisher
cd zphisher
# Run tool (ONLY in authorized environment)
bash zphisher.shRemove Immediately After Use:
cd ~
rm -rf zphisherAlternative Package Method (if available):
pkg install zphisher # May not be in standard repos
zphisher
pkg remove zphisherSafer Alternatives for Learning:
- Use dedicated cybersecurity training platforms (TryHackMe, HackTheBox)
- Enroll in authorized security certification courses (CEH, OSCP)
- Practice in isolated virtual lab environments only
- Never test on production systems or real users
Before using ANY security tool:
-
Get Written Permission
- From system owner
- Specifying scope of testing
- Defining allowed techniques
- With clear time boundaries
-
Use Proper Environment
- Isolated lab networks
- Virtual machines
- Test servers you own
- Never on public/production systems
-
Document Everything
- What tools you used
- When and where you tested
- Findings and recommendations
- Maintain audit trail
-
Report Responsibly
- Follow responsible disclosure practices
- Give vendors time to patch vulnerabilities
- Don't publish exploits publicly
- Work through proper channels
Instead of using tools on real systems, consider:
Free Learning Platforms:
- TryHackMe - Beginner-friendly labs
- HackTheBox - Advanced challenges
- PentesterLab - Web app security
- OverTheWire - CTF challenges
Certifications:
- CompTIA Security+
- Certified Ethical Hacker (CEH)
- Offensive Security Certified Professional (OSCP)
- GIAC Security Essentials (GSEC)
Bug Bounty Programs (Legal):
These provide legal ways to practice security skills with permission and potentially earn rewards.
# Update all packages
pkg update -y && pkg upgrade -y
# Clean package cache
apt clean && pkg clean
# Remove unused packages
apt autoremove -y && pkg autoclean
# Clear command history (optional)
cat /dev/null > ~/.bash_history && history -cpkg update -y && pkg upgrade -y && \
apt clean && pkg clean && \
pkg autoclean && apt autoremove -y && \
cat /dev/null > ~/.bash_history && history -cThese commands will PERMANENTLY DELETE files and settings. BACKUP FIRST!
# Remove AVcleaner symlink and directory
rm -rf $PREFIX/bin/clean
rm -rf ~/AVcleaner
# Remove cache and config directories
rm -rf ~/.cache
rm -rf ~/.termux
rm -rf ~/.ssh
rm -rf ~/.config/mpv# β’οΈ THIS DESTROYS YOUR ENTIRE TERMUX INSTALLATION β’οΈ
# Only use if you want to start completely fresh
rm -rf $PREFIX
# or
rm -rf /data/data/com.termux/files/home
rm -rf /data/data/com.termux/files/usrAfter running this, you must:
- Close Termux completely
- Clear app data from Android settings
- Reinstall Termux from F-Droid
- Termux Wiki - Complete official documentation
- Termux.dev - Official website
- GitHub Organization - All official repositories
- Package Search - Find available packages
- Package Registry - Complete package list (JSON, YAML, Markdown)
- Termux App - Main application
- Termux Packages - Package build scripts
- Termux API - Android API access
- Termux Boot - Boot scripts
- Termux Float - Floating window
- Termux Styling - Color schemes & fonts
- Termux Widget - Home screen shortcuts
- Termux X11 - X11 server
π Comprehensive Resource Lists:
| Repository | Description | Stars |
|---|---|---|
| Awesome Termux | Most comprehensive curated list of resources | 1k+ |
| Awesome-Termux (T4P4N) | Bash scripts, Wiki, Articles, Shells | 500+ |
| Awesome Termux (adrianogil) | General awesome list | 300+ |
| Awesome Termux Hacking | Security tools collection | 400+ |
| All-in-one Tools | Hacking tools compilation | 200+ |
| Termux Command Handbook | Detailed command reference | 100+ |
π§ All-in-One Installers:
| Tool | Description | Tools Count | Stars |
|---|---|---|---|
| AllHackingTools | Complete hacking tools installer | 200+ | 3.5k+ |
| Tool-X | Multi-purpose tool installer | 370+ | 2.5k+ |
| Lazymux | Lazy tool installer for Termux | 100+ | 2k+ |
π Security & Penetration Testing:
- Metasploit Framework - Penetration testing framework
- Nmap - Network scanner
- SQLMap - SQL injection tool
- Social-Engineer Toolkit - SET framework
- TBomb - SMS/Call bomber (educational)
- Seeker - Location tracking tool
- Zphisher - Phishing tool (authorized use only)
π οΈ System & Root Tools:
- agnostic-apollo/sudo - Root wrapper for Termux
- agnostic-apollo/tudo - Termux user context wrapper
- TSU - Termux SU wrapper
π» Development Tools:
- Code-Server - VS Code in the browser
- Jupyter Notebook - Interactive Python notebooks
- NodeJS Projects - JavaScript runtime
π¨ Customization:
- Termux-Monet - Material You themes
- Oh My Termux - Termux customization
- Termux-Style - Color schemes
π± Media & Entertainment:
π§ Proot Distributions:
| Distribution | Repository | Description |
|---|---|---|
| Andronix | AndronixApp/AndronixOrigin | Multiple Linux distros installer |
| TermuxAlpine | TermuxAlpine/TermuxAlpine | Alpine Linux in Termux |
| TermuxArch | TermuxArch/TermuxArch | Arch Linux in Termux |
| Nethunter | Hax4us/Nethunter-In-Termux | Kali NetHunter installer |
| Ubuntu | Built-in | proot-distro install ubuntu |
| Debian | Built-in | proot-distro install debian |
| Fedora | Built-in | proot-distro install fedora |
| Arch Linux | Built-in | proot-distro install archlinux |
Browse by Topic:
- π termux - All Termux projects
- π termux-guide - Tutorials and guides
- π termux-tools - Useful tools (sorted by stars)
- π termux-commands - Command references
- π termux-environment - Setup configs
- π termux-hacking - Security tools
- π termux-proot - Proot-distro projects
- π termux-book - Learning materials
- π termux-style - Themes & customization
- π awesome-termux - Awesome lists
- Reddit - r/termux - Active community (100k+ members)
- GitHub Discussions - Official discussions
- Gitter Chat - Live chat support
- Discord Servers - Community Discord
- Telegram Groups - Telegram community
- XDA Forums - Developer discussions
- Bug Reports - Official issue tracker
- Package Issues - Package problems
| App | Purpose | F-Droid Link |
|---|---|---|
| Termux | Main terminal app | Download |
| Termux:API | Access Android system features | Download |
| Termux:Boot | Run scripts on device boot | Download |
| Termux:Float | Floating terminal window | Download |
| Termux:Styling | Color schemes and fonts | Download |
| Termux:Widget | Home screen shortcuts | Download |
| Termux:Tasker | Tasker integration plugin | Download |
| Termux:X11 | X11 server for GUI apps | GitHub |
Note: Termux:X11 is only available on GitHub, not F-Droid.
- Official Wiki - Comprehensive documentation
- Termux Cheat Sheet - Quick reference
- Package Documentation - Package management guide
- Development Wiki - For developers
- Tech Raj - Termux tutorials and tips
- Hacker's Hub - Security and hacking tutorials
- Termux Lab - Tips, tricks, and how-tos
- Dev Empty - Programming in Termux
- Termux.dev Blog - Official blog
- Linux On Android - Related guides
- Android Central - Beginner guides
- Medium - Termux - Community articles
- Browse termux-book topic on GitHub
- Termux App - Official Termux application repository
- Termux Wiki - Comprehensive documentation
- Termux Packages - Package build scripts
- Termux Guide - Tutorials and guides for Termux
- Termux Topics - All Termux-related projects
- Termux Commands - Command references and examples
- Termux Tools - Useful tools (sorted by stars)
- Termux Tool - Additional tool collections
- Termux Environment - Setup and configuration (sorted by stars)
- Termux Proot - Proot-distro related projects
- Termux Style - Themes and customization
- Termux Book - Comprehensive learning materials
- Termux Command Handbook - Detailed command reference
- Termux Hacking - Security testing tools
β οΈ WARNING: Use only for authorized testing and educational purposes
- Termux Recommended for Android - Android-optimized tools and apps
Automation & Scripts:
- Termux-services
- Termux-widget
- Termux-boot
Desktop Environments:
- AnLinux
- Andronix
- Termux-desktop
Development Tools:
- Termux-api
- Code-server
- Git integration tools
System Utilities:
- Termux-styling
- Termux-monet (Material You themes)
- Font installers
Media & Entertainment:
- mpv configurations
- YouTube downloaders
- Music players
Comprehensive Resource Lists:
- Awesome Termux - Most comprehensive curated list
- Awesome-Termux (T4P4N) - Bash scripts, Wiki, Articles, Shells
- Awesome Termux (adrianogil) - General awesome list
- Awesome Termux Hacking - Security tools collection
- All-in-one Termux Tools - Hacking tools list
Tool Installers & Package Managers:
- AllHackingTools - All-in-One hacking tools installer
- Tool-X - 370+ tool installer for Termux
- Lazymux - Termux tool installer
Popular Individual Tools:
- Metasploit - Penetration testing framework
- Nmap - Network scanner
- SQLMap - SQL injection tool
- Social-Engineer Toolkit - SET framework
- Ngrok - Secure tunneling
- TBomb - SMS/Call bombing tool
- Seeker - Location tracking tool
Root & Advanced Tools:
- agnostic-apollo/sudo - Root wrapper for Termux
- agnostic-apollo/tudo - Termux user context wrapper
- TSU - Termux SU wrapper
Linux Distributions in Termux:
- Andronix - Install Linux distros
- TermuxAlpine - Alpine Linux installer
- TermuxArch - Arch Linux installer
- Nethunter-In-Termux - Kali NetHunter installer
Package & Registry Information:
- Termux Packages Registry - Complete package list (Markdown, JSON, YAML)
- Termux Package Search - Official package search
# Search for Termux packages on GitHub
# Visit: https://github.com/search?q=termux
# Clone interesting repositories
git clone https://github.com/username/repo-name
# Star repositories you find useful
gh repo view owner/repo --webIf you create useful Termux tools or guides:
- Add relevant topics to your repository
- Use tags:
termux,termux-tool,termux-guide, etc. - Write clear documentation
- Share on r/termux community
- Termux Wiki - Complete documentation
- Termux GitHub - Official organization
- Package Search - Find available packages
- Termux.dev - Official website
- r/termux - Reddit community
- Termux Gitter - Live chat
- Discord Servers - Community discussions
- Termux Forum - GitHub discussions
- F-Droid (Recommended) - Latest official version
- GitHub Releases - Direct APK downloads
β οΈ DO NOT use Play Store version - It's outdated and no longer maintained
- Termux:API - Access Android features
- Termux:Boot - Run scripts on boot
- Termux:Float - Floating terminal window
- Termux:Styling - Color schemes and fonts
- Termux:Tasker - Tasker integration
- Termux:Widget - Home screen shortcuts
- Termux:X11 - X11 server for GUI apps
- Awesome Termux - Curated list of resources
- Termux Cheat Sheet - Quick reference
- Android Terminal - Beginner guides
- Tech Raj - Termux tutorials
- Hacker's Hub - Security and hacking
- Termux Lab - Tips and tricks
- Dev Empty - Programming in Termux
- Termux.dev Blog - Official blog
- Linux On Android - Related guides
- XDA Forums - Community discussions
# Reset repository mirrors
termux-change-repo
# Force update
pkg update --force
# Fix broken packages
pkg upgrade -y
dpkg --configure -a# Re-run storage setup
termux-setup-storage
# Check permissions in Android Settings:
# Settings β Apps β Termux β Permissions β Storage# Reload environment
source ~/.bashrc
# Or create new shell session
exit
# Then reopen Termux| Resource | URL |
|---|---|
| Download Termux (F-Droid) | https://f-droid.org/packages/com.termux/ |
| Official GitHub | https://github.com/termux/termux-app |
| Documentation Wiki | https://wiki.termux.com |
| Package Search | https://packages.termux.dev |
| Reddit Community | https://reddit.com/r/termux |
| Topic | URL |
|---|---|
| Termux Guide | https://github.com/topics/termux-guide |
| Termux Tools (Popular) | https://github.com/topics/termux-tools?o=desc&s=stars |
| Termux Environment | https://github.com/topics/termux-environment?o=desc&s=stars |
| Termux Commands | https://github.com/topics/termux-commands |
| Termux Hacking | https://github.com/topics/termux-hacking |
| Termux Proot | https://github.com/topics/termux-proot |
| Termux Book | https://github.com/topics/termux-book |
| Termux Style | https://github.com/topics/termux-style |
| Awesome Termux | https://github.com/topics/awesome-termux |
| Termux Awesome List | https://github.com/topics/termux-awesome-list |
| Command Handbook | https://github.com/BlackTechX011/Termux-Command-Handbook |
| Repository | Description |
|---|---|
| Awesome Termux | Most comprehensive curated resource list |
| Awesome-Termux (T4P4N) | Bash scripts, Wiki, Articles, Shells |
| Awesome Termux (adrianogil) | General awesome list |
| Awesome Termux Hacking | Security tools collection |
| All-in-one Tools | Hacking tools compilation |
| Tool | Description | Stars |
|---|---|---|
| AllHackingTools | All-in-One installer for 200+ tools | 3.5k+ |
| Tool-X | Install 370+ hacking tools | 2.5k+ |
| Lazymux | Termux tool installer | 2k+ |
| App | Purpose | F-Droid Link |
|---|---|---|
| Termux:API | Android system access | https://f-droid.org/packages/com.termux.api/ |
| Termux:Boot | Run on device boot | https://f-droid.org/packages/com.termux.boot/ |
| Termux:Float | Floating window | https://f-droid.org/packages/com.termux.window/ |
| Termux:Styling | Themes & fonts | https://f-droid.org/packages/com.termux.styling/ |
| Termux:Widget | Home shortcuts | https://f-droid.org/packages/com.termux.widget/ |
| Termux:Tasker | Tasker integration | https://f-droid.org/packages/com.termux.tasker/ |
Q: Do I need root access to use Termux?
A: No, Termux works perfectly without root. However, some advanced features (like low-level system access) require root.
Q: Can I run Linux GUI applications?
A: Yes, using VNC or Termux:X11. However, GUI apps can be slow on mobile devices.
Q: Is Termux legal to use?
A: Yes, Termux itself is completely legal. However, using certain tools (like hacking tools) without authorization is illegal.
Q: Why should I avoid the Play Store version?
A: The Play Store version is outdated and no longer maintained. Always use F-Droid or GitHub releases.
Q: How much storage does Termux need?
A: Basic installation: ~50MB. With common packages: 200-500MB. Full desktop environment: 2-4GB+.
Q: How do I grant storage permission?
A: Run termux-setup-storage and allow the permission prompt.
Q: Can I access my phone's files from Termux?
A: Yes, after running termux-setup-storage, use ~/storage/shared to access internal storage.
Q: How do I update all packages?
A: Run pkg update && pkg upgrade -y
Q: What's the difference between pkg and apt?
A: pkg is a wrapper around apt with better defaults. Both work, but pkg is recommended.
Q: Package installation fails with "Unable to locate package"
A: Run pkg update first to refresh the package list.
Q: Command not found after installing a package
A: Restart Termux or run source ~/.bashrc
Q: Termux keeps getting killed in the background
A: Disable battery optimization for Termux in Android Settings β Apps β Termux β Battery.
Q: How do I fix broken packages?
A: Run dpkg --configure -a and then pkg upgrade -y
Q: Storage permission denied
A: Re-run termux-setup-storage and check Android Settings β Apps β Termux β Permissions.
Q: Can I run Docker in Termux?
A: Not directly. Docker requires kernel-level features. Use proot-distro instead for containers.
Q: How do I get a desktop environment?
A: Install VNC server and a lightweight desktop (XFCE recommended). See VNC Server Setup.
Q: Can I use Termux as an SSH server?
A: Yes! Install openssh with pkg install openssh and run sshd.
Q: How do I backup Termux?
A: See the Backup & Restore section for detailed instructions.
Q: Can I run Windows programs?
A: Not directly. You can try Wine, but compatibility is limited on ARM devices.
Q: Can I do Python development in Termux?
A: Absolutely! Termux fully supports Python, pip, and virtual environments.
Q: Does Node.js work in Termux?
A: Yes, Node.js works perfectly. Install with pkg install nodejs.
Q: Can I compile C/C++ code?
A: Yes, install clang with pkg install clang and compile normally.
Q: Is there an IDE for Termux?
A: Use vim, neovim, nano, or install code-server for VS Code in your browser.
Q: Is it safe to install hacking tools?
A: The tools themselves are legal for educational and authorized testing. Using them maliciously is illegal.
Q: Can others access my Termux if I run an SSH server?
A: Only if you expose it to the network. By default, SSH runs on localhost only. Always use strong passwords and SSH keys.
Q: How do I secure my Termux installation?
A: See Security Best Practices section.
Q: Why is Termux slow?
A: Could be due to: old device, low RAM, battery optimization, or heavy packages. Try lighter alternatives.
Q: Can I increase Termux performance?
A: Yes, see Performance Optimization for tips including swap files and process management.
Q: Desktop environments are too slow, what should I do?
A: Use command-line tools instead, or try a minimal window manager like openbox instead of full desktop environments.
- Exit commands: The original script used
exitafter every command block. These have been preserved but can be removed for continuous operation. - Battery optimization: Disable battery optimization for Termux in Android settings to prevent background process termination.
- F-Droid vs Play Store: Always use Termux from F-Droid or GitHub. The Play Store version is outdated and deprecated.
- Google Play versions (2026): Builds like
googleplay.2026.01.07are heavily restricted to comply with Play Store policies. F-Droid/GitHub versions have full functionality. - Root access: Not required for any of these commands. Use
tsufor root operations only if you have a rooted device. - Version managers: Modern approach (2026) recommends using
mise,asdf, oruvfor managing multiple language versions instead of installing them all system-wide. - Configuration persistence:
~/.termux/termux.propertiesand~/.termux/colors.propertiesshould be backed up separately as they define your appearance settings.
Last Updated: January 29, 2026
Termux Stable Version: 0.118.3 (May 2025)
Termux Beta Version: 0.119.0-beta.3 (May-June 2025)
Bootstrap: 2026.01.11-r1 and newer
Android Compatibility: 7.0+ (API 24+)
Recommended Source: F-Droid or GitHub Releases
Guide maintained by: Community contributors
Based on: Official Termux documentation and community best practices
Contributions: Pull requests welcome
Special thanks to:
- Termux development team
- agnostic-apollo (Awesome Termux list)
- All tool developers and maintainers
- Termux community on Reddit and GitHub
This guide is provided as-is for educational purposes. Individual tools and packages mentioned have their own licenses.
MIT License - Feel free to share, modify, and distribute with attribution.