Password-protected OTA Web IDE for MicroPython on ESP32 / ESP32-S3 boards.
- Web Interface Screenshot
This project allows you to write, upload, and execute MicroPython code directly from your browser — no serial connection needed.
It includes:
- A minimal web IDE served directly from the ESP32-S3
- Username/password protection for secure local access
- File management (save, delete, run)
- Real-time log output via web interface
- Built-in hard reset
Save & Run code directly from browser
Run existing .py files stored on device
Delete unwanted files
Real-time serial log output on webpage
Basic authentication (default: admin / admin) # can be changed
Works on ESP32 and XIAO ESP32-S3 boards
Shell which also you control more and get test script without saving on ROM on the device
Before uploading any Python files (boot.py, ota.py, etc.), make sure your ESP32 or ESP32-S3 board is running MicroPython firmware.
You can flash it easily using either Thonny IDE (recommended for beginners) or esptool.py (for command-line users).
-
Download and Install Thonny
- 🔗 Thonny IDE Official Site
- Works on Windows, macOS, and Linux.
-
Connect the ESP32 Board
- Plug your ESP32/ESP32-S3 into your computer using a USB cable.
- Make sure the cable supports data transfer (not just charging).
-
Select Interpreter
- In Thonny, go to:
Tools → Options → Interpreter - Choose:
Interpreter: “MicroPython (ESP32)”
Port: the serial port where your board is connected.
- In Thonny, go to:
-
Install/Update MicroPython Firmware
- Click “Install or update MicroPython” in the same menu.
- Thonny will automatically detect your board and list available firmware versions.
- Select the latest stable firmware for your board (ESP32 or ESP32-S3).
- Click “Install” and wait until you see “Done!”.
- RePlug your ESP32/ESP32-S3 into your computer using a USB cable.
- go to:
Tools → Options → InterpreterChoose:
Port: the serial port where your board is connected. - This to make sure that after installing the firmware , your machine communicate with esp 32.
-
Verify
- After flashing, open Thonny’s Shell (bottom panel).
- You should see something like:
MicroPython v1.xx on 2025-xx-xx; ESP32 module with ESP32S3 >>> - You can now type:
to confirm your board is ready.
import os os.listdir()
If you prefer command line or Thonny doesn’t detect the board:
-
Install esptool
pip install esptool
-
Download the Correct Firmware
- Go to MicroPython Downloads
- Download the .bin file for your specific ESP32/ESP32-S3 variant.
-
Erase Existing Flash
- Replace /dev/ttyUSB0 with your board’s port:
esptool.py --chip esp32 erase_flash
-
Flash MicroPython
esptool.py --chip esp32 --port /dev/ttyUSB0 --baud 460800 write_flash -z 0x1000 firmware.bin
-
Verify Flash
- Reconnect the board, open any serial terminal (Thonny, minicom, PuTTY).
- You should see the same MicroPython boot message as shown above.
Upload both of these files to your ESP device: boot.py & ota.py
You can use Thonny, ampy, or WebREPL to transfer these files.
Edit the following section in your boot.py file before uploading:
SSID = "Your_WiFi_SSID"
PASSWORD = "Your_WiFi_Password"Once uploaded.
Your Thonny console will show something like: Wi-Fi: STA IP: 192.168.1.14 HTTP server on 192.168.1.14 port 80
Use this IP address in your browser to access the Web IDE.
Open ota.py in Thonny and locate:
USER = "admin"
PASSWORD = "admin"Change both fields to your desired username and password, then re-upload ota.py. This secures your OTA Web IDE against unauthorized access.
After saving both files and restarting the ESP32: 1. Open Thonny IDE. 2. Connect to your ESP32 via MicroPython (USB). 3. Watch the Shell/console output — it will display your board’s assigned IP address. 4. Copy that IP and open it in Chrome/Brave/Firefox/anyotherbrower: http://
1. Connect your ESP32 to the same Wi-Fi network.
2. Open the IP shown in Thonny (http://192.168.x.x).
3. Enter your login credentials.
4. Write or paste your MicroPython script.
5. Click Save & Run to execute immediately.
6. Watch the live logs on the same webpage.
7. If you update the script values just hard rest to ensure safe running.
TuzaaBap