The ESP32 hosts a web page with ON/OFF buttons that control two LEDs from your phone or laptop.
Project_5_ESP32_LED_Switch_Web_Server.ino, then open it in the Arduino IDE (setup: Project 0b). Remember to set your Wi‑Fi credentials.
http://<ESP_IP>/ returns an HTML page./26/on). The ESP32 sees the path, switches the LED, and re‑sends the page.That request‑then‑respond loop is the heart of every web‑server project in this kit.
Edit these two lines in the sketch with your network name and password:
const char* ssid = "REPLACE_WITH_YOUR_SSID"; const char* password = "REPLACE_WITH_YOUR_PASSWORD";
| Qty | Part | Notes |
|---|---|---|
| 1 | ESP32 · breadboard · jumper wires | — |
| 2 | LED | Have polarity |
| 2 | 220 Ω resistor | One per LED |

For each LED: GPIO → 220 Ω → LED anode (long leg); cathode (short leg) → GND.
After uploading, open Serial Monitor at 115200 and press EN/RESET:
============================================== Project 5: ESP32 LED Switch Web Server ============================================== LED 1 -> GPIO 26 LED 2 -> GPIO 27 Connecting to Wi-Fi: MyNetwork .... Wi-Fi connected! Open this address in your browser: http://192.168.1.42 ----------------------------------------------
Open that address in a browser on the same network:

[WEB] New client connected [WEB] LED 1 (GPIO 26) -> ON [WEB] Client disconnected
http:// address. The raw dump is still there, commented out, for debugging.
| Symptom | Likely cause | Fix |
|---|---|---|
| Stuck on "Connecting…" dots | Wrong credentials / 5 GHz network | Fix SSID+password; use 2.4 GHz |
| Page won't load | Phone on a different network | Same LAN for phone + ESP32 |
| LED reversed | Polarity | Long leg toward the 220 Ω side |
| Monitor blank | Wrong baud | Set it to 115200 |