ESP8266 Web Server Tutorial

Written by Rui SantosDownload free eBook with Arduino projects here

If you want to learn more about the ESP8266 module, first read my Getting Started Guide for the ESP8266 WiFi Module. In this project you’ll create a standalone web server with an ESP8266 that can toggle two LEDs.

ESP8266 Web Server Tutorial

Why flashing your ESP8266 module with NodeMCU?

NodeMCU is a firmware that allows you to program the ESP8266 modules with LUA script. And you’ll find it very similar to the way you program your Arduino. With just a few lines of code you can establish a WiFi connection, control the ESP8266 GPIOs, turning your ESP8266 into a web server and a lot more.

Where to buy?

You can click here to get this module on eBay for less than $4.


  • RX -> TX
  • TX -> RX
  • CH_PD -> 3.3V
  • GPIO 0 -> GND
  • VCC -> 3.3V
  • GND -> GND
  • Downloading NodeMCU Flasher for Windows

    After wiring your circuit, you have to download the NodeMCU flasher. It’s a .exe file that you can download using one of the following links:

    You can click here to find all the information about NodeMCU flasher.

    Flashing your ESP8266

    Open the flasher that you just downloaded and a window should appear (as shown in the following figure).

Press the button “Flash” and it should start the flashing process immediately (You might have to change some of the settings  on the Advanced tab). After finishing this process, it should appear a green circle with a check icon.


Now follow the schematics bellow to create your web server to control two LEDs.


For more detail: ESP8266 Web Server Tutorial

About The Author

Scroll to Top