
NodeMCU ESP8266 Pinout: GPIO Map, V2 vs V3
NodeMCU ESP8266 Pinout in 30 Seconds The D labels on the board are not GPIO numbers: D1 = GPIO5, D2 = GPIO4, D4 = GPIO2. Write D1 in Arduino code and you get the right pin; write 1 and you get the TX pin. The pins you can use without a second thought are D1, D2, D5, D6 and D7. D3, D4 and D8 pick the boot mode, and D0 has no interrupt or PWM. Default I2C: SDA D2 (GPIO4), SCL D1 (GPIO5). Default SPI: SCK D5, MISO D6, MOSI D7, CS D8. The only analog pin is A0. NodeMCU has a voltage divider on it, so it reads 0-3.3 V as 0-1023. The pins are 3.3 V. Don’t feed them a 5 V signal; power the board with 5 V through Vin. V2 (Amica) uses a CP2102, V3 (LoLin) a CH340. V3 is wider and swaps two reserved pins for VU (USB 5 V) and GND. The GPIO map is identical. NodeMCU is the board that put the ESP8266 on a breadboard with USB and a regulator. It is ten years old and the ESP32 has long since arrived, but it is still the board most people pick for their first Wi-Fi project, mostly because it is cheap and almost every tutorial and library already supports it. ...