The ESP32-S3-WROOM-1 (specifically the popular N16R8 variant with 16MB Flash and 8MB PSRAM) exposes 45 physical GPIO pins, but they are not universally interchangeable. Unlike older generations, the S3 integrates native USB OTG, replacing the UART-only boot paradigm, and relies on specific strapping pins to dictate boot modes and flash voltage. Below is the definitive hardware mapping to keep your board out of a boot loop.
| Pin Number | Name / Label | Primary Function | Boot Strapping Role (Reset State) | 5V Tolerant? |
|---|---|---|---|---|
| GPIO0 | SPI_BOOT_MODE | General I/O / Boot Button | LOW = USB Boot; HIGH = SPI Flash Boot | No (3.3V Max) |
| GPIO3 | JTAG_SEL | General I/O | LOW = JTAG via USB; HIGH = JTAG via GPIO | No (3.3V Max) |
| GPIO45 | VDD_SPI_SEL | General I/O | LOW = SPI Flash at 3.3V; HIGH = 1.8V | No (3.3V Max) |
| GPIO46 | LOG_PRINT_SEL | General I/O | LOW = Boot log to USB; HIGH = Boot log to UART | No (3.3V Max) |
| GPIO19 | USB_D- | Native USB OTG Data Minus | N/A (Dedicated USB PHY) | No (3.3V Max) |
| GPIO20 | USB_D+ | Native USB OTG Data Plus | N/A (Dedicated USB PHY) | No (3.3V Max) |
Decoding the ESP32-S3-WROOM Pinout Rows
When reading the official Espressif ESP32-S3-WROOM datasheet, the pinout table dictates physical limits, not just software assignments. The 'Primary Function' column tells you what the pin does best in hardware, while the 'Boot Strapping Role' column defines what the silicon reads on that pin the exact millisecond the EN (Enable) line goes high after a reset.
Rows People Get Wrong
- GPIO45 (VDD_SPI_SEL): Makers frequently assign GPIO45 to drive a relay or read a sensor, only to find their board crashes randomly. If GPIO45 is pulled HIGH during boot, the S3 switches the internal SPI flash VDD to 1.8V. Since the WROOM-1 module uses 3.3V flash, this brownouts the memory and halts execution. Rule: Never pull GPIO45 high during reset.
- GPIO35 through GPIO42: On the N16R8 (Octal SPI) variant, these pins are hardwired internally to the PSRAM and Flash chips. They do not break out to standard GPIO functions. Attempting to use them for I2C or PWM will cause immediate memory faults.
- GPIO0 (The Boot Button): While often used as a standard input button in code, its hardware role is paramount. If held LOW during reset, the chip bypasses the SPI flash entirely and enters the native USB ROM bootloader. If your project has a sensor pulling GPIO0 low on startup, your code will never run.
Mains IoT Integration: NEC vs. IEC Wiring Standards
The ESP32-S3 pinout is universal, but the moment you use those GPIOs to trigger a 10A relay module for a smart home project, you cross from low-voltage silicon into high-voltage regional wiring standards. When wiring the load side of your relay to mains voltage, the wire color codes you must follow depend entirely on your region's electrical code. Miswiring a switched neutral instead of a switched line is a lethal hazard.
| Function | NEC (US / Canada) | IEC 60446 (EU / Harmonized) | Old UK (Pre-2004) |
|---|---|---|---|
| Line (Hot / Phase) | Black (or Red) | Brown | Red |
| Neutral | White (or Grey) | Blue | Black |
| Earth (Ground) | Bare / Green / Green-Yellow | Green-Yellow | Green-Yellow |
Which Standard Applies to You?
If you are building in North America, the NFPA 70 (NEC) governs your wiring; Line is Black, Neutral is White. If you are in the EU, UK, or Australia, IEC 60446 harmonized colors apply (Brown/Blue/Green-Yellow). The 'Old UK' column is critical for retrofitting ESP32 smart switches into pre-2004 British homes, where the black wire is actually the live Line, not the Neutral. Always verify with a non-contact voltage tester before terminating wires to your relay's COM and NO (Normally Open) terminals.
Safe Interpretation When Module Markings Are Faded or Missing
Clone boards, reflowed modules, and heavy handling often rub the silkscreen text off the ESP32-S3-WROOM's metal RF shield or the underlying PCB castellations. Guessing pin identities on a bare module is a fast track to bricking the chip. Here is how to safely map the pins when visual markings are compromised.
- Identify Ground (GND) via the RF Shield: Set your multimeter to continuity mode. Place the black probe on the large metal RF shield covering the ESP32-S3 silicon. Probe the edge castellations with the red probe. Any pin that beeps with near-zero resistance (< 1 ohm) is a GND pin. The S3-WROOM typically has multiple GND pads for thermal and RF grounding.
- Locate VCC (3.3V) via Decoupling Capacitors: Look for the cluster of small ceramic capacitors near the module's edge on the carrier board. The VCC pin is always directly tied to the positive side of these decoupling caps. Measure continuity from the capacitor's positive pad to the module pins to confirm.
- Find the EN (Enable) Pin: The EN pin is tied to a 10k pull-up resistor leading to VCC, and usually a 1uF capacitor leading to GND (to delay boot and prevent brownout resets). If you measure a pin that shows a slow charging curve on your multimeter's diode/continuity test (due to the capacitor), you have likely found EN.
Never apply 5V to a 'guessed' VCC pin. The ESP32-S3-WROOM internal LDO (if present on the carrier board) expects 5V on the 5V input pad, but the module's VCC pad strictly requires 3.3V. If you are wiring a bare WROOM module without a carrier board, you must supply regulated 3.3V directly to the 3V3 pin, or you will instantly destroy the internal power matrix.






