Today we will learn how to run VS Code on android. Using this trick, you can turn your Android tablet or smartphone into a fully functional Dev Environment ? Whether you are a student on a budget or a developer who needs a quick bug fix while traveling, the ability to run Visual Studio Code on Android is a game-changer.
In this guide, We are going to install the full desktop version of VS Code using Termux and Code-Server.
Why Run VS Code on Android?
- Great Extension Support: Install Python, Prettier, and more.
- Built in Terminal: Run Git commands, NPM, or Python scripts directly.
- No Root Required: This method is safe and works on almost any modern Android device.
- Easy TO USE: Code anywhere.
Prerequisites
Before we begin, ensure you have the following:
- Install Termux. Don’t use the Play Store version, as it is no longer updated. Download the latest APK from F-Droid or Github.
- Stable Internet Connection is needed For downloading the Required packages.
Installing VS Code on Android
1. Update and Prepare Termux
First, we need to ensure your environment is up to date. Open Termux and enter the following commands
termux-change-repo
Then select the default mirror.
Next, give Termux access to your phone’s storage so you can save your coding projects:
termux-setup-storage
Click “Allow” when the system prompt appears.
Next, Update your Termux
pkg update && pkg upgrade -y
Step 2: Install the VS Code Server
We will use the Termux User Repository which provides the most stable version of code-server.
pkg install tur-repo -y
pkg install code-server -y
Step 3: Launch and Secure Your Server
Now, let’s start the server for the first time to generate your configuration file:
code-server
NOTE: VS Code is password-protected by default for your security. To find your password, press Ctrl + C to stop the server, then run:
cat ~/.config/code-server/config.yaml
Copy the password found next to the password: field
Step 4: Access VS Code in Your Browser
- Start the server again by typing code-server.
- Open your Chrome browser.
- In the address bar, type http://localhost:8080
- Enter your password and click Login.
PRO Tip: To make it feel like a real app, go to your browser settings and select “Add to Home Screen.” This will add Web App to your Launcher. You can open it and This removes the address bar and gives you more screen space
Frequently Asked Questions (FAQ)
Can I run Python or Node.js?
Yes! You can install Python (pkg install python) or Node.js (pkg install nodejs) directly in Termux, and the VS Code terminal will be able to run them perfectly.
Do I need Root?
Nope. This method uses a proot environment which runs entirely within the user space of Android.
How DO I stop the server?
Go back to the Termux app and press Ctrl + C. To start it again later, just type code-server.



