ESP32 Pinout and Touch Pin Guide: Every Board We Sell
Picking the wrong pin is the number one reason a first ESP32 project does nothing. A button that never reads, an LED that flickers on upload, a touch pad that is dead. This page is the cheat sheet I wish I'd had: every board we sell, the pins that matter, and the gotchas.
New to reading pinout diagrams? Episode 6 of my Foundations series walks through one step by step:
Which board has capacitive touch?
Capacitive touch is what lets you use a patch of conductive fabric as a button. It is built into some ESP32 chips and missing from others, so check this before you buy.
| Board | Chip | Touch pins |
|---|---|---|
| ESP32 30-pin (micro-USB and USB-C) | ESP32 | 10 pins: GPIO 4, 0, 2, 15, 13, 12, 14, 27, 33, 32 |
| ESP32 38-pin USB-C | ESP32 | 10 pins: GPIO 4, 0, 2, 15, 13, 12, 14, 27, 33, 32 |
| ESP32-S3 SuperMini | ESP32-S3 | GPIO 1 to 14 |
| ESP32-C3 SuperMini (black and pink) | ESP32-C3 | None |
| ESP32-C3 with 0.42 inch screen | ESP32-C3 | None |
| ESP32-C3 with 25-light matrix | ESP32-C3 | None |
If you want fabric touch buttons, use the classic ESP32 boards or the S3. On the C3 boards you can still use a fabric switch, just as a normal button (see the common mistakes below).
Reading touch pins in code
Use touchRead(pin). The two chip families behave in opposite directions, which catches almost everyone out once:
- Classic ESP32: the number goes down when you touch the pad.
- ESP32-S3: the number goes up when you touch the pad. Read a baseline value at start-up and compare against it instead of hard-coding a number.
Touch values change with the size of the pad, the wire length and even the weather, so always test on your actual build.
ESP32 30-pin and 38-pin dev boards
- Flash pins (GPIO 6 to 11): connected to the board's memory. Never use them.
- Input-only pins (GPIO 34, 35, 36, 39): fine for sensors and buttons, but they cannot output, and have no internal pull-up.
- Strapping pins (GPIO 0, 2, 5, 12, 15): read at boot to decide how the chip starts. A wire or component pulling them the wrong way can stop the board uploading or booting. GPIO 12 is the classic trouble-maker.
- ADC2 pins and Wi-Fi: analogue readings on the ADC2 pins (GPIO 0, 2, 4, 12 to 15, 25 to 27) stop working while Wi-Fi is on. Use ADC1 pins (32 to 39) for analogue readings in Wi-Fi projects.
- Default I2C: SDA = GPIO 21, SCL = GPIO 22. Default SPI: MOSI 23, MISO 19, SCK 18, CS 5.
ESP32-S3 SuperMini
- USB-C on the top edge. Left side, top to bottom: TX (43), RX (44), GPIO 1 to 7. Right side: 5V, GND, 3V3, GPIO 13, 12, 11, 10, 9, 8.
- The onboard RGB LED and the blue LED share GPIO 48.
- Touch: GPIO 1 to 14.
- Strapping pins: GPIO 0, 3, 45, 46. Avoid GPIO 3 for anything that pulls it high or low at boot.
- GPIO 13 is on ADC2, so analogue readings there stop working when Wi-Fi or ESP-NOW is running.
- Native USB, so serial comes through the USB-C port.
ESP32-C3 SuperMini
- 4 MB flash, 400 KB RAM, 11 usable GPIO plus 4 analogue inputs.
- Blue LED on GPIO 8, BOOT button on GPIO 9.
- Strapping pins: GPIO 2, 8, 9.
- No capacitive touch.
- Serial runs over the built-in USB. In PlatformIO, switch on USB CDC at boot (see the settings section) or the Serial Monitor stays blank.
- The built-in antenna is modest. Keep metal and fabric with conductive thread away from it, and keep the board toward the outside of a garment if you want a strong signal.
ESP32-C3 with 0.42 inch screen
I tested this board myself, so these pins are confirmed:
| Part | Pin |
|---|---|
| OLED screen (SSD1306, 72 x 40 pixels), I2C data (SDA) | GPIO 5 |
| OLED screen, I2C clock (SCL) | GPIO 6 |
| OLED I2C address | 0x3C |
| Onboard RGB LED (WS2812) | GPIO 2 |
- The screen uses its own pins, so GPIO 5 and 6 are already taken if you want to add other I2C parts. You can share the same two pins with another I2C device, such as a sensor.
- The RGB LED is on GPIO 2, which is a strapping pin. A floating LED data line can show bright white while the board is uploading. That is normal.
- Use the
olikraus/U8g2library with its 72 x 40 SSD1306 setting. - No capacitive touch.
ESP32-C3 with 25-light matrix
Also tested and confirmed:
| Part | Pin |
|---|---|
| 25 WS2812B lights (data line) | GPIO 8 |
| Header pin labels | GND, 3V, GPIO 0, GPIO 1 |
- Light order: the lights run row by row, starting at the top left and moving left to right along every row. So light number = row x 5 + column (counting from 0), and the grid is 5 x 5.
- GPIO 8 is a strapping pin, so don't hold it low at boot.
- Use the Adafruit NeoPixel library (
adafruit/Adafruit NeoPixel). Keep the brightness low: 25 bright lights draw a lot of current. - Serial needs the USB CDC settings below.
- No capacitive touch.
Powering from a battery
- ESP32-S3 SuperMini: has an onboard LiPo charger. Solder the battery to the BAT+ and BAT- pads on the back. It charges at about 100 mA, or about 300 mA if you bridge the BOOST pads. The charge LED flashes when no battery is connected and is solid while charging.
- ESP32 30-pin, 38-pin and C3 SuperMini: no onboard LiPo charger. Use a separate charging board, and never feed a raw LiPo into the 5V pin.
- If you add a slide switch, put it in the positive wire from the battery, not in the ground wire. A charger will only charge when the switch is on.
- Always check the battery polarity before connecting. Reversed polarity can destroy a board instantly.
PlatformIO board settings
These are the settings I use. Each goes in your platformio.ini.
ESP32 30-pin and 38-pin
[env:esp32dev]
platform = espressif32
framework = arduino
board = esp32dev
monitor_speed = 115200
ESP32-C3 SuperMini, C3 screen board and C3 matrix board
[env:c3]
platform = espressif32
framework = arduino
board = esp32-c3-devkitm-1
monitor_speed = 115200
build_flags =
-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
monitor_rts = 0
monitor_dtr = 0
ESP32-S3 SuperMini
[env:esp32s3_supermini]
platform = espressif32
framework = arduino
board = esp32-s3-devkitc-1
board_upload.flash_size = 4MB
board_build.flash_mode = qio
board_build.arduino.memory_type = qio_qspi
board_build.partitions = default.csv
build_flags =
-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
monitor_speed = 115200
If a SuperMini will not upload, hold the BOOT button, tap RESET, release BOOT, then upload again.
Common mistakes
- Using a flash pin. GPIO 6 to 11 on the 30 and 38-pin boards. The board crashes or will not boot.
- Expecting touch on a C3. The C3 chips have no capacitive touch. Use a fabric switch as a plain button with a pull-up resistor instead.
- Blank Serial Monitor. On boards with built-in USB, add the USB CDC flags shown above.
- Touch numbers going the wrong way. Classic ESP32 reads lower when touched, the S3 reads higher.
- Strapping pins. A button or LED on a strapping pin can stop the board uploading or starting.
- Analogue pins and Wi-Fi. ADC2 stops working with Wi-Fi on.
- Feeding 5V into a 3.3V pin. ESP32 pins are 3.3V only.
- Bright white lights on upload. A floating LED data line does this. It goes away once the code runs.
Related
- Going deeper on the classic ESP32? The ESP32 Dev Module pin guide sorts every pin into safe, strapping, input-only and reserved.
- Lighting up LEDs? See Troubleshooting common NeoPixel problems.
- Want to try touch with fabric? Our conductive fabrics make great touch pads, and the ESP32 boards collection has every board on this page.
- Step-by-step builds using these boards are on the CMozMaker YouTube channel.
Accurate as of October 2026. Board makers change layouts and chips from time to time, so if something on your board looks different, check the silkscreen printed on the board.