ESP32 Pinout Reference: Which GPIO pins should you use?

The ESP32 chip comes with 48 pins with multiple functions. Not all pins are exposed in all ESP32 development boards, and there are some pins that cannot be used.

There are many questions on how to use the ESP32 GPIOs. What pins should you use? What pins should you avoid using in your projects? This post aims to be a simple and easy to follow reference guide for the ESP32 GPIOs.

The figure below illustrates the ESP-WROOM-32 pinout. You can use it as a reference if you’re using an ESP32 bare chip to build a custom board:

ESP32 Pinout chip ESP-WROOM-32

Note: not all GPIOs are accessible in all development boards, but each specific GPIO works in the same way regardless of the development board you’re using. If you’re just getting started with the ESP32, we recommend reading our guide: Getting Started with the ESP32 Development Board.

ESP32 Pinout Reference: Which GPIO pins should you use?

ESP32 Peripherals

The ESP32 peripherals include:

The ADC (analog to digital converter) and DAC (digital to analog converter) features are assigned to specific static pins. However, you can decide which pins are UART, I2C, SPI, PWM, etc – you just need to assign them in the code. This is possible due to the ESP32 chip’s multiplexing feature.

Although you can define the pins properties on the software, there are pins assigned by default as shown in the following figure (this is an example for the ESP32 DEVKIT V1 DOIT board with 36 pins – the pin location can change depending on the manufacturer).

ESP32 DEVKIT V1 DOIT board with 36 pins Pinout

Additionally, there are pins with specific features that make them suitable or not for a specific project. The following table shows what pins are best to use as inputs, outputs and which ones you need to be cautious.

The pins highlighted in green are OK to use. The ones highlighted in yellow are OK to use, but you need to pay attention because they may have unexpected behavior mainly at boot. The pins highlighted in red are not recommended to use as inputs or outputs.

0pulled upOKoutputs PWM signal at boot
1TX pinOKdebug output at boot
2OKOKconnected to on-board LED
3OKRX pin HIGH at boot
5OKOKoutputs PWM signal at boot
6xxconnected to the integrated SPI flash
7xxconnected to the integrated SPI flash
8xxconnected to the integrated SPI flash
9xxconnected to the integrated SPI flash
10xxconnected to the integrated SPI flash
11xxconnected to the integrated SPI flash
12OKOKboot fail if pulled high
14OKOKoutputs PWM signal at boot
15OKOKoutputs PWM signal at boot
34OKinput only
35OKinput only
36OKinput only
39OKinput only

Continue reading for a more detail and in-depth analysis of the ESP32 GPIOs and its functions.

Input only pins

GPIOs 34 to 39 are GPIs – input only pins. These pins don’t have internal pull-ups or pull-down resistors. They can’t be used as outputs, so use these pins only as inputs:

  • GPIO 34
  • GPIO 35
  • GPIO 36
  • GPIO 39

SPI flash integrated on the ESP-WROOM-32

GPIO 6 to GPIO 11 are exposed in some ESP32 development boards. However, these pins are connected to the integrated SPI flash on the ESP-WROOM-32 chip and are not recommended for other uses. So, don’t use these pins in your projects:

  • GPIO 6 (SCK/CLK)
  • GPIO 7 (SDO/SD0)
  • GPIO 8 (SDI/SD1)
  • GPIO 9 (SHD/SD2)
  • GPIO 10 (SWP/SD3)
  • GPIO 11 (CSC/CMD)

Capacitive touch GPIOs

The ESP32 has 10 internal capacitive touch sensors. These can sense variations in anything that holds an electrical charge, like the human skin. So they can detect variations induced when touching the GPIOs with a finger. These pins can be easily integrated into capacitive pads, and replace mechanical buttons. The capacitive touch pins can also be used to wake up the ESP32 from deep sleep.

Those internal touch sensors are connected to these GPIOs:

  • T0 (GPIO 4)
  • T1 (GPIO 0)
  • T2 (GPIO 2)
  • T3 (GPIO 15)
  • T4 (GPIO 13)
  • T5 (GPIO 12)
  • T6 (GPIO 14)
  • T7 (GPIO 27)
  • T8 (GPIO 33)
  • T9 (GPIO 32)

Learn how to use the touch pins with Arduino IDE: ESP32 Touch Pins with Arduino IDE

Analog to Digital Converter (ADC)

The ESP32 has 18 x 12 bits ADC input channels (while the ESP8266 only has 1x 10 bits ADC). These are the GPIOs that can be used as ADC and respective channels:

  • ADC1_CH0 (GPIO 36)
  • ADC1_CH1 (GPIO 37)
  • ADC1_CH2 (GPIO 38)
  • ADC1_CH3 (GPIO 39)
  • ADC1_CH4 (GPIO 32)
  • ADC1_CH5 (GPIO 33)
  • ADC1_CH6 (GPIO 34)
  • ADC1_CH7 (GPIO 35)
  • ADC2_CH0 (GPIO 4)
  • ADC2_CH1 (GPIO 0)
  • ADC2_CH2 (GPIO 2)
  • ADC2_CH3 (GPIO 15)
  • ADC2_CH4 (GPIO 13)
  • ADC2_CH5 (GPIO 12)
  • ADC2_CH6 (GPIO 14)
  • ADC2_CH7 (GPIO 27)
  • ADC2_CH8 (GPIO 25)
  • ADC2_CH9 (GPIO 26)

Learn how to use the ESP32 ADC pins:

Note: ADC2 pins cannot be used when Wi-Fi is used. So, if you’re using Wi-Fi and you’re having trouble getting the value from an ADC2 GPIO, you may consider using an ADC1 GPIO instead, that should solve your problem.

The ADC input channels have a 12 bit resolution. This means that you can get analog readings ranging from 0 to 4095, in which 0 corresponds to 0V and 4095 to 3.3V. You also have the ability to set the resolution of your channels on the code, as well as the ADC range.

The ESP32 ADC pins don’t have a linear behavior. You’ll probably won’t be able to distinguish between 0 and 0.1V, or between 3.2 and 3.3V. You need to keep that in mind when using the ADC pins. You’ll get a behavior similar to the one shown in the following figure.

Digital to Analog Converter (DAC)

There are 2 x 8 bits DAC channels on the ESP32 to convert digital signals into analog voltage signal outputs. These are the DAC channels:

  • DAC1 (GPIO25)
  • DAC2 (GPIO26)


There is RTC GPIO support on the ESP32. The GPIOs routed to the RTC low-power subsystem can be used when the ESP32 is in deep sleep. These RTC GPIOs can be used to wake up the ESP32 from deep sleep when the Ultra Low Power (ULP) co-processor is running. The following GPIOs can be used as an external wake up source.

  • RTC_GPIO0 (GPIO36)
  • RTC_GPIO3 (GPIO39)
  • RTC_GPIO4 (GPIO34)
  • RTC_GPIO5 (GPIO35)
  • RTC_GPIO6 (GPIO25)
  • RTC_GPIO7 (GPIO26)
  • RTC_GPIO8 (GPIO33)
  • RTC_GPIO9 (GPIO32)
  • RTC_GPIO10 (GPIO4)
  • RTC_GPIO11 (GPIO0)
  • RTC_GPIO12 (GPIO2)
  • RTC_GPIO13 (GPIO15)
  • RTC_GPIO14 (GPIO13)
  • RTC_GPIO15 (GPIO12)
  • RTC_GPIO16 (GPIO14)
  • RTC_GPIO17 (GPIO27)

Learn how to use the RTC GPIOs to wake up the ESP32 from deep sleep: ESP32 Deep Sleep with Arduino IDE and Wake Up Sources


The ESP32 LED PWM controller has 16 independent channels that can be configured to generate PWM signals with different properties. All pins that can act as outputs can be used as PWM pins (GPIOs 34 to 39 can’t generate PWM).

To set a PWM signal, you need to define these parameters in the code:

  • Signal’s frequency;
  • Duty cycle;
  • PWM channel;
  • GPIO where you want to output the signal.

Learn how to use ESP32 PWM with Arduino IDE: ESP32 PWM with Arduino IDE


The ESP32 has two I2C channels and any pin can be set as SDA or SCL. When using the ESP32 with the Arduino IDE, the default I2C pins are:

  • GPIO 21 (SDA)
  • GPIO 22 (SCL)

If you want to use other pins, when using the wire library, you just need to call:

Wire.begin(SDA, SCL);

Learn more about I2C communication protocol with the ESP32 using Arduino IDE: ESP32 I2C Communication (Set Pins, Multiple Bus Interfaces and Peripherals)


By default, the pin mapping for SPI is:



All GPIOs can be configured as interrupts.

Learn how to use interrupts with the ESP32:

Strapping Pins

The ESP32 chip has the following strapping pins:

  • GPIO 0
  • GPIO 2
  • GPIO 4
  • GPIO 5 (must be HIGH during boot)
  • GPIO 12 (must be LOW during boot)
  • GPIO 15 (must be HIGH during boot)

These are used to put the ESP32 into bootloader or flashing mode. On most development boards with built-in USB/Serial, you don’t need to worry about the state of these pins. The board puts the pins in the right state for flashing or boot mode. More information on the ESP32 Boot Mode Selection can be found here.

However, if you have peripherals connected to those pins, you may have trouble trying to upload new code, flashing the ESP32 with new firmware or resetting the board. If you have some peripherals connected to the strapping pins and you are getting trouble uploading code or flashing the ESP32, it may be because those peripherals are preventing the ESP32 to enter the right mode. Read the Boot Mode Selection documentation to guide you in the right direction. After resetting, flashing, or booting, those pins work as expected.

Pins HIGH at Boot

Some GPIOs change its state to HIGH or output PWM signals at boot or reset. This means that if you have outputs connected to these GPIOs you may get unexpected results when the ESP32 resets or boots.

  • GPIO 1
  • GPIO 3
  • GPIO 5
  • GPIO 6 to GPIO 11 (connected to the ESP32 integrated SPI flash memory – not recommended to use).
  • GPIO 14
  • GPIO 15

Enable (EN)

Enable (EN) is the 3.3V regulator’s enable pin. It’s pulled up, so connect to ground to disable the 3.3V regulator. This means that you can use this pin connected to a pushbutton to restart your ESP32, for example.

GPIO current drawn

The absolute maximum current drawn per GPIO is 40mA according to the “Recommended Operating Conditions” section in the ESP32 datasheet.

ESP32 Built-In Hall Effect Sensor

The ESP32 also features a built-in hall effect sensor that detects changes in the magnetic field in its surroundings.

Wrapping Up

We hope you’ve found this reference guide for the ESP32 GPIOs useful. If you have more tips about the ESP32 GPIOs, please share by writing a comment down below.

If you’re just getting started with the ESP32, we have some great content to get started:

Thanks for reading.

Build Web Server projects with the ESP32 and ESP8266 boards to control outputs and monitor sensors remotely. Learn HTML, CSS, JavaScript and client-server communication protocols DOWNLOAD »

Build Web Server projects with the ESP32 and ESP8266 boards to control outputs and monitor sensors remotely. Learn HTML, CSS, JavaScript and client-server communication protocols DOWNLOAD »

Enjoyed this project? Stay updated by subscribing our weekly newsletter!

126 thoughts on “ESP32 Pinout Reference: Which GPIO pins should you use?”

  1. Excellent , thanks i have been confused with this issue since there are so m any pins and most have diffrenee possibilities. too many variations to remember them withoutu consulting

  2. Very useful and well presented info. It might be useful to point out that the Adafruit Feather pinouts are not compatible with the similar looking DEVKIT V1 DOIT board. Reference:

    • Hi Doug.
      Yes, the Huzza 32 from Adafruit has a slightly different pinout.
      But the guide you refer does a great job explaining each individual pin.
      Thanks for sharing.
      Sara 🙂

    • Hi Doug,
      I am absolutely brand new to this whole “trade” I guess I would call it, but I’m trying to get up to speed as quickly as I can to complete a 16 x 16 Led matrix graduation cap for my daughter, but everywhere I’ve looked there is very little or no information on this other than lots of videos that crank out music while showing someone’s finished project in operation. In summary, I have an ESP32 -WHOOM – 32D which is a 5v or 3.5v board with different pinouts than what I’ve seen here, so I was wondering if anyone has the same board ?

  3. Hi,

    This is a fine guide, but my experience shows that not all ADC pins can be used when Wifi is started, for me only ADC0 worked ?

    thanks Peter

    • Hi Peter.
      Thanks for sharing that info.
      As I can remember we only had trouble in one specific project in using GPIO4 for analog reading with WiFi.
      We should try each individual ADC pin with WiFi and see if we have any trouble.
      Thank you
      Sara 🙂

  4. Bit confused! I have a NodeMCU-32S board, which pins are Analog and which are digital?? You say GPIO34-39 are input only – so I could use all the other pins (if setMode is set to OUTPUT) to turn on LED’s etc?

    What about the GPIO’s you say to not use? GPIO6 – 11?


    • yes you can use any pin from 0-33 as outputs. you could also use gpio 6-11 but it would interfere with the spi communications between the esp’s processor and it’s flash memory and it is thus a bad idea.

  5. Thanks a billion. I purchased my first ESP32 the day I first read about it. I thought my knowledge of the 8266 should get me started. BIG MISTAKE. I ordered 4 of them to begin with, and up until a few weeks ago, they have laid capture in a plastic parts box. At long last I found one project that might work with them, and learned how to get the Arduino IDE to write to them. Well my Frogger try ended up pretty bad, never could get it working right, however I did get it to display, so I guess that is something. That said, I have learned more in the last few minutes reading this page then I knew about this little sports car of devices. Again, thanks billions I shall go on reading the rest of your pages. I knew I had come on something good when I first found your pages a few years ago, and you keep the education going and going.

  6. Great work!.. Is it possible to powering esp32 by external supply? I mean, 5v to Vin Pin and Ground to ground. I’ve tried many ways but it is impossible to me. It just work with USB powering. Thanks in advance.

    • Hi Pablo.
      Yes, it is possible to power the ESP32 using external power supply.
      What exactly are you using to power the ESP32?
      Sara 🙂

      • Hi Sara. I’m using 5v power supply direct to V5 pin but doesnt work. It looks such reboot and never run normal, but if I connnect to usb 1a it works fine. I’ve tried 3 boards and it doesnt work. It is chinese, wrover, most common, v4

          • Hi Pablo.
            That’s the same ESP32 board that we usually work with.
            That very weird.
            It should power up by supplying 5V to the VIN pin. Make sure you’re supplying enough current.
            Otherwise, I have no idea why that is happening.
            Sara 🙂

        • might be a problem with the power supply:

          solution Tantal capacitor 47uF between GND and VCC

          see also:

  7. Hey, I need some kind of help…

    I have a custom design with ESP32. My GPIO0 is held LOW, my EN pin is connected to 3.3v. When I boot, I get the “waiting for download” prompt. However, I always get the famous “Timed out waiting for packet header” error.

    Any help is appreciated 🙂

    • Hi Alex.
      When uploading code to the ESP32, you should press the BOOT button, which is the same of held GPIO 0 to LOW. There are other pins that influence uploading code to the ESP32, such as GPIO2, GPIO12, and GPIO15.
      Take a look at the following article:
      It is very informative when it comes to boot mode selection.
      I’ve never experimented with a custom design with only the ESP32 chip (I’ve just experimented with development boards with the chip), so I’m not aware of other stuff that you may need to pay attention to.
      Anyway, I hope you found the article useful and you can solve your problem.
      Sara 🙂

    • Not sure if this is still relevant, but I encountered a similar issue in my custom PCB project with the ESP32-WROVER-B. Datasheet is

      I hit two snags:

      – using a strapping pin for my SPI display. Pay special attention to all pins mentioned in section 2.3 “Strapping Pins”. They all are trouble. So other than IO0 (for boot mode) I did not connect any of them
      – missing pullups on #EN and IO0 and missing capacitor on #EN. The datasheet is a bit sneaky about these. The example schematic doesn’t mention the pullup for IO0 and the capacitance for #EN is 0.2uF (as there are two circuits mentioning that). I experimented and even use 0.3uF for my capacitor on #EN.

      With this setup, I got the board to reliably flash using esptool.

      My project can be found here:

      You can use KiCad 5 to see the schematic that I verified works for me.

  8. After days of confusion between many articles and distinguishing the
    PINs name and functions, this article made my day. 🙂
    Many thanks for your well written article.

  9. @ bestware – I think you are mistaken.
    There are indeed two separate I2C interfaces. These are referred to as I2C0 and I2C1.
    See e.g. section 11.4 in the ESP32 Technical Reference Manual – where all the registers for control of the two interfaces are listed.
    You can route the SDA and SCL pins of each I2C interface to any GPIO (which can be output and which is in the correct power domain). Please check the technical reference manual if you are interested in details.
    But as Sara Santos correctly explains in the tutorial, the Arduino Wire Library allows one of the I2C’s to be operated – and only on GPIO 21 and 22.

          • Here is a link to one?


  10. You didnt mention about the UARTS apart from saying there are 3. I read somewhere that UART2 on GPIO 16/17 cant be used, or at least those pins cant be used, and I see no other mention of GPIO16/17 above. Do you know what the story is there ?

    Thanks for a great write-up by the way, I come back to it often !

    • Hi Bob.
      As far as I know, you can use GPIO 17 and 16 as UARTs, as well as GPIO 1 and GPIO 3.
      UART0: (GPIO 1 and GPIO3)
      UART2: (GPIO 17 and GPIO 16)

      UART1: (GPIO 9 and GPIO10) – these are connected to the ESP32 SPI flash memory, so you can’t use them. But, you can use UART1 by defining other pins on the HardwareSerial. Andreas Spies has a great video explaining this:

      Thank you for your interest in our tutorials.

      • Interestingly I was just doing a small ESP32 Arduino project and I couldn’t toggle GPIO 16 or 17 in my code. It took a while to realize what was going on, but I eventually moved to different pins. After that I did some digging I discovered that pins 16 and 17 are used by PSRAM on the WROVER modules.

        Pin 16 is used as the chip select for PSRAM, and 17 is used for the clock signal. It would probably be good to note this above.

        You can see it on the schematics on the WROVER datasheet:

        • Hi.
          Thanks for sharing that.
          Can you share what your project does?
          I’ve used GPIO 16 successfully with projects that involve taking a photo (I guess this doesn’t use PSRAM). However, if trying to video stream in high-resolution settings, it might crash because it needs to use PRAM.

          • I can give you the broad strokes. I was prototyping a industrial controller using a ESP32 using a ESP32 DevKitC — which uses a WROVER module and not a WROOM). I needed multiple serial ports, I2C, SPI, and assorted GPIO. Hence the conflict with 16&17

  11. GPIO 5, 12 (MTDI) and 15 (MTDO) are strapping pins, i.e. not OK to use during boot.

    GPIO 12 must be low (0) and GPIO 5 and 15 high (1) during boot.

  12. 101/5000
    I am having problems with analogRead (). It does not work.
    I need to read the value of the sensor. Thank you

    • Can you use a different GPIO? Any of the following GPIOs should be safe to use with Wi-Fi + AnalogRead():
      ADC1_CH0 (GPIO 36)
      ADC1_CH1 (GPIO 37)
      ADC1_CH2 (GPIO 38)
      ADC1_CH3 (GPIO 39)
      ADC1_CH4 (GPIO 32)
      ADC1_CH5 (GPIO 33)
      ADC1_CH6 (GPIO 34)
      ADC1_CH7 (GPIO 35)
      GPIO 15 (the one you’re using belongs to ADC2 and any ADC2 pin causes some issues when used with Wi-Fi).

      Try with GPIO 33 for example and let me know your results.

  13. I have a ESPWROOM-32 module, but it has 38 pins. What pin layout do I use? Top 3.3V on left, GND on right and 5V bottom left and CLK on right. Putting the USB connect at the bottom. Help?

    • Hi Logan.
      To use the pinout, please check the labels on the board and then compare with the pinout that we have.
      Usually, in different boards, the same labels refer to the same GPIO.
      For example, the pin marked as RX2 on the silkscreen of the board is GPIO16. D2 is GPIO2 and so on.
      I hope this helps.

    • Hi.
      As mentioned in the article:
      “ADC2 pins cannot be used when Wi-Fi is used. So, if you’re using Wi-Fi and you’re having trouble getting the value from an ADC2 GPIO, you may consider using an ADC1 GPIO instead, that should solve your problem.”

  14. I have exactly the board of this tutorial with 36 pins.
    I connected GPIO16 and GPIO17 to a standard optocoupled relay board and when the asyncwebserver sends a web page to the client the relays drive crazy.
    Avoid those pins.

  15. hi, i have a DOIT ESP32 devkitV1(clone) –
    pinout seems to match the real doit devkitv1 🙂

    in some of the info i have read on the internet it has a onboard Temperature sensor,
    yet i dont seem to be able to find examples that use it? or what specific sensor it is? – i have used the Hall sensor onboard fine.

    is this temp sensor accessible, and worth the effort (will it just show me how much my board has warmed up, or will it give me usable environment data?)

    ps — is there a way (software) to use the RED power led?? i can use the BLUE one, LED_BUILTIN (its gpio2) but can i use the power led?

  16. A really good guide, thanks
    I have only one question, with the devkit (30 gpio), how can I take a manual RESET button outside? Thanks again 🙂

  17. I wanted to take the time to thank you for these series of articles. I have a number of these generic AliExpress/Aokin ESP-WROOM-32 boards and while I was able to use them without much trouble, it always bothered me that I didn’t have any “solid” documentation for them. Now I know exactly what I am dealing with.

    Again, Thank You…

  18. I went through a similar process figuring out the Adafruit Esp32 Huzzah Feather board, and created my own reference chart. If it’s useful to anyone, help yourself:

  19. Very useful, before creating any new project i always keep this page in front of me. Thanks
    Update GPIO15 function for Enabling/Disabling Debugging Log Print over U0TXD During Booting very useful for final deliverable product

  20. Hello can u help me?
    i’m using esp32 for my project and i using pressure sensor .
    the output of the sensor, i using GPIO36 but it doesn’t work..
    Thank You

  21. Thank You for this excellent resource! Random Nerds is definitely helping to educate and expand this community’s capabilities. ☺

  22. Very informative article indeed, thank you.

    I am planning to do my own home automation project using ESP32-WROOM-32U module.
    I simply don’t need all the IO pins, and am planning to breakout only the pins I need to minimize the PCB footprint (IC2 and IO 16-27).
    I used a ‘Test board Burn Fixture Programmer’ to upload the sketch, and all future updates should be OTA updates. Hence, I don’t need to mess about with the boot mode once the module is soldered to the PCB.

    The question is, do I have to connect any of the Strapping Pins to anything if I want a normal boot and occasional OTA updates?

      • Thanks for your help Sara.
        I have read the link you provided, and found it very informative, but could not find a direct answer to my question.

        Through trial and error, I found that providing 3.3V and GND did not work, but by using a pullup resistor on pin 3 (EN pin), the ESP started normally and I could flash it over the air without having to press anything or short any pins. Later I found this information already provided in the datasheet on page 15.

        Best regards,

    • Hi.
      With the ESP32, you can use any GPIO that can be input for the TRIG pin and any GPIO that can be output for the ECO pin.
      For example, you can use GPIO 26 and 27.

  23. Thank you very much for this informative article …but what about the librarys that works with arduino, are all compatible with the ESP32.

    Best regards,

  24. Hi
    In DOIT dev kit GPIO21 and GPIO22 are used by I2C bus. Why those pins are not mentioned as I2C interface in the bare module, in the case if I decide to develop my own custom board.

    • Hi.
      In fact, with the ESP32 you can choose almost any pin to act as I2C.
      However, when using Arduino IDE libraries, it chooses GPIO 21 and GPIO22 as default I2C pins.

  25. Hello,
    I have a project developed on TTGO T7 Ver 1.0
    It is a simple keypad 3X4 reader, plus and RFID decoder (get RFID data from TX of RDM6300 and extract the ID of the card) Match the keyboard input with the one store on EEprom, match the RFID with the stored on EEprom and if the match send an encrypted signal (like Go) through Bluetooth to a slave identical TTGO chip.
    I wonder if the project can work if i try to use a regular ESP32 NodeMCU.
    TTGO chips are only in China and very hard to get through Ali. ESP32 is easier to buy , even from Amazon. This is my problem.

  26. Hi,
    Does the VIN pin also work as a 5V output when ESP board is powered from USB? Mine doesn’t but I’ve seen you do it on your tutorials…

  27. Thank you, very useful!
    I migrated my latest project (self balancing gyrosopic two wheeler) from Arduino Uno to ESP32 because the processor is just too slow. Loop() runs in less than a millisecond. Wow.

  28. ESP32 PICO kit V4 require manual RESET after powering off.
    After powering ON the device, the software doesn’t boot up automaticully. I have to press the reset button. This means that the PICO device is completely unusable as Alarm Device, due to a failure in automatic restart after power break down! Googling for solutions bring me up to install a 4.7 k resistance between +3.3V and IO0 pin. This works only if the powerOFF take place for severals seonds!
    Is there an other solution to activate the automaticully StartUp after a power faillure ?

  29. Hello Sara,
    thank you very much for this realy useful reference guide for the ESP32 GPIOs .
    I have one DS18B20 connceted to the ESP32 GPIO 14 and sometime, the ESP32 has a problem to conect to the WiFi.
    Could the problem be in the badly selected GPIO, as mentioned above?

    Best regards

  30. Hi,

    I’m a bit confused about the “Input only” pins as well. I did a board and used one of them (IO34) as an output, didn’t work of course.

    The original ESP32 WROOM Pinout picture (also on top of this article), doesn’t mark them as “input only”.
    they have a PWM “snake line”, doesn’t make sense for an input only.
    GPIO stands for General Purpose Input OUTPUT… how can this be Input only???


  31. Very helpful.
    1) Any chance for an explanation about the UART pins or include this link to this webpage: []
    2) It would also be super helpful to have an example of UART being used, maybe using it to show two ESP32s communicating via UART0 and UART2.
    3) Some explanation on SoftwareSerial or a link to this page: [] and a URL to as an example []. I think SoftwareSerial is no longer being included in IDE because I just installed latest clean version of Arduino IDE 1.8.13 Windows and I get an error ‘include SoftwareSerial.h not found’ (or I am doing something wrong as something isn’t making sense to me!) when I use code like yours above.

    Sorry if any of these things have already been done, I tried your website search for “UART2” and get no results.
    Many thanks,

  32. Any idea why float batteryLevel = map(analogRead(12), 0.0f, 4095.0f, 0, 100); seems to give back 100 no matter how bad the battery is?

  33. Hi Sara and Rui,
    I’m new to ESP32, and found your posts extremely helpful. Thanks.
    I’m preparing a project to be used with Home Assistant, but I have three questions regarding the pinout:
    1- You mention that if my project uses WiFi (which is the case) I should not use ADC2. So, is Wifi killing 10 of my GPIO? I’m a little confused, since many ADC2 are green on your table. If I exclude all ADC2 and all non-recommended pins, I would end up with just two “touch” pins – 32 and 33. Is that so?
    2- If I load the ESP32 with 2 touch pads, 4 sensors (thermistor, LDR, humidity, PIR) on GPIO 33, 32, 35, 34, 39, 36 and 10 pulse keys on GPIO 23, 22, 1, 21, 19, 18, 5, 17 and 16 do you think it would work?
    3- Do you have similar pinout recommendations of the ESP32-S2?
    Thanks in advance.

    • Hi.
      1- What we mean is that you can’t use ADC in the ADC2 pins when using wi-fi. You can use those pins as standard input or output or touch pins, and they will work fine. They won’t work properly as ADC pins.
      2- I think those pins will work, but it is always better to test everything before making any permanent connections.
      3- At the moment, we don’t have any articles for the ESP32-S2.
      I hope this helps.

  34. So I tried the tutorial and sent you a message about things that didn’t work but never got an answer. Basically one issue was in the code const char had to be changed to char, also no matching function for call to HttpClient http


Leave a Comment

Download our Free eBooks and Resources

Get instant access to our FREE eBooks, Resources, and Exclusive Electronics Projects by entering your email address below.