Insight Into ESP32 Sleep Modes & Their Power Consumption

The ESP32 is an impressive piece of silicon—it packs two powerful CPU cores that can crunch data at hundreds of megahertz, connect over Wi-Fi and Bluetooth, and control the world through its GPIO pins.

But as a wise engineer once said,

“with Great Power comes Great Power Consumption“

When your project is plugged into the wall, you don’t really worry about how much current it draws. In battery-powered projects, though, every milliamp matters. A few extra milliamps here and there can mean the difference between weeks and months of uptime.

Fortunately, the ESP32 isn’t just powerful; it’s also smart about power. It offers a range of sophisticated power-saving modes that, when used correctly, can dramatically reduce power consumption without sacrificing functionality.

In this tutorial, we’ll explore those power-saving modes, understand when to use each one, and learn how to stretch battery life as far as possible while still getting the most out of the ESP32. Let’s dive in!

ESP32 Power Modes

The ESP32 offers five distinct operational modes:

  • Active Mode
  • Modem-sleep Mode
  • Light-sleep Mode
  • Deep-sleep Mode
  • Hibernation Mode

All of these modes, except for Active Mode, are designed to reduce power consumption when the chip doesn’t need to operate at full capacity. They do this by turning off certain parts of the chip while keeping others running.

To better understand how these modes work, it helps to know what’s actually inside the ESP32. The ESP32 contains a dual-core 32-bit microprocessor along with 448 KB of ROM, 520 KB of SRAM, and 4 MB of flash memory. It also includes a Wi-Fi module, a Bluetooth module, a cryptographic accelerator (which is a special co-processor designed to handle encryption tasks), an RTC (Real-Time Clock) module, and several digital peripherals (such as standard GPIO, SPI, I2C, and UART). All of these parts can be controlled by the ESP32 depending on what it needs to do.

The block diagram of the ESP32 chip is shown below.

esp32 functional block diagram

With this in mind, let’s go through the different ESP32 power modes, starting with the one that uses the most power.

ESP32 Active Mode

Active Mode is the default state of the ESP32, where the chip operates at its full operational capacity. In this mode, all digital peripherals are active, the CPU clocks are running, and the RF module, which handles Wi-Fi and Bluetooth communications, is fully capable of both transmitting and receiving data. Because so many components are turned on at the same time, the ESP32 uses the most energy in this mode.

esp32 active mode functional block diagram

The power consumption in Active Mode varies greatly and is primarily determined by the activity of the RF module, which is the most power-hungry part of the ESP32.

During Wi-Fi transmission, peak current consumption can range anywhere from 180 mA to 240 mA, depending on the modulation scheme (the method used to encode data), the transmission power level (TX power), and the data rate being used.

Wi-Fi Reception mode is less demanding than transmission but still requires a significant amount of power. During Wi-Fi reception, the device consumes between 95 mA and 100 mA.

Bluetooth Classic and Bluetooth Low Energy (BLE) operations generally consume less power compared to Wi-Fi. When transmitting Bluetooth packets at 0 dBm, the chip typically draws around 130 mA, and during Bluetooth reception it consumes between 95 mA and 100 mA.

According to the ESP32 datasheet, the RF current consumption in Active Mode is as follows:

Operational StateWork ModePower OutputTypical Current
Wi-Fi TX802.11b, DSSS 1 Mbps+19.5 dBm240 mA
Wi-Fi TX802.11g, OFDM 54 Mbps+16 dBm190 mA
Wi-Fi TX802.11n, OFDM MCS7+14 dBm180 mA
Wi-Fi RX802.11b/g/nN/A95 – 100 mA
Operational StateWork ModePower OutputTypical Current
BT/BLE TXTransmit0 dBm130 mA
BT/BLE RXReceiveN/A95 – 100 mA

This mode, without a doubt, consumes the most current and is the least efficient. To save power, especially for battery-powered projects, you must eventually switch to one of the other power-saving modes.

ESP32 Modem Sleep

Modem-sleep mode is a commonly used method for keeping a Wi-Fi connection active while greatly reducing the average amount of power the ESP32 uses. It’s specifically designed for situations where the ESP32 is connected to a router (AP) as a Wi-Fi station (STA) but does not need to transfer data continuously. In other words, the device stays connected, but it does not waste energy when no real communication is happening.

The way Modem-sleep works relies on a clever mechanism called the Delivery Traffic Indication Map, or DTIM for short.

When the ESP32 connects to a Wi-Fi router, it negotiates a DTIM interval—a specific window of time during which the router agrees to hold onto (buffer) any data that needs to be sent to the ESP32 instead of sending it right away. Between these intervals, the ESP32 turns off its RF module (Wi-Fi/Bluetooth radio) while keeping the CPU running.

DTIM-Beacon

Just before the next DTIM beacon arrives, the ESP32 turns its receiver back on for a moment to check if the router is holding any data for it. If there’s no data, it immediately turns off the RF module again. By repeating this cycle, the ESP32 keeps its Wi-Fi connection alive while dramatically lowering power use, because the power-hungry RF module stays off most of the time.

In Modem-sleep, the CPU remains fully operational, the clock is configurable, and all digital peripherals stay active just like in Active mode. The major difference is that the RF module is turned off most of the time.

esp32 modem sleep functional block diagram

Even with the RF module off, the CPU cores still consume power, and the amount of power they use is directly proportional to their clock frequency (how fast they’re running). The higher the CPU frequency, the more current the chip will draw.

The CPU can operate at various frequencies including 80 MHz, 160 MHz, and 240 MHz. At the highest speed of 240 MHz, the ESP32 usually consumes between 30 mA and 68 mA, while at the lowest speed of 80 MHz it typically uses around 20 mA to 25 mA.

Here’s a detailed breakdown of current consumption at different CPU frequencies:

240 MHzDual-core chip(s)30 mA – 68 mA
Single-core chip(s)N/A
160 MHzDual-core chip(s)27 mA – 44 mA
Single-core chip(s)27 mA – 34 mA
80 MHz
(Normal speed)
Dual-core chip(s)20 mA – 31 mA
Single-core chip(s)20 mA – 25 mA

ESP32 Light Sleep

Light-sleep mode acts as a middle ground between high-performance processing and true deep-sleep states. In this mode, the ESP32 uses a technique called Clock Gating.

What is Clock Gating?

Clock gating is a popular power management technique that reduces dynamic power in digital circuits by temporarily stopping the clock signal to parts of the circuit that are not currently in use, allowing them to pause their activity without being completely turned off. This saves power while still allowing the device to wake up quickly.

In this mode, the ESP32 stops the clock signals going to the CPU cores and to most of the digital peripherals. Because these parts are not actively running, the overall power consumption drops to about 0.8 mA.

esp32 light sleep functional block diagram

Even though the ESP32 is mostly paused in this state, it can still wake up in several ways.

  • GPIO Interrupts: Changes in voltage level on digital GPIO pins can trigger the chip to wake up, allowing it to respond to physical button presses or sensor signals.
  • UART Wake-up: Activity on the UART RX line can trigger a wake-up, which means the device can sleep until it detects incoming serial data.
  • Timers: Internal high-precision timers can be programmed to trigger a wake-up after a predefined duration, perfect for scheduled tasks or periodic sensor readings.

This allows the ESP32 to sleep while waiting for an event without losing the ability to react quickly.

In Light-sleep mode, the ESP32 features “Full RAM Retention“, which preserves all the contents of its RAM before entering sleep. When the chip wakes up, it continues running from the exact line of code that comes right after the sleep command, so it feels as if the program paused for a moment rather than restarting or losing data.

The key advantage of Light-sleep mode is its extremely short wake-up latency, which is less than 1 millisecond. This rapid resumption makes it practical to enter Light-sleep even for very short idle periods, since the chip can wake up almost instantly when needed, saving energy without causing any noticeable delay in operation.

ESP32 Deep Sleep

Deep-sleep is the most important low-power mode for battery-powered IoT devices. In this mode, the ESP32 aggressively reduces power consumption by cutting off power to the CPU cores, the system RAM, and all digital peripherals.

The only components that remain active during Deep-sleep include:

  • RTC Controller: The state machine that manages sleep duration and wake-up triggers.
  • RTC Peripherals: A specialized set of low-power peripherals including the on-chip temperature sensor, ADCs, RTC GPIOs, and touchpads.
  • RTC Memory: Divided into RTC Fast Memory (8 KB) and RTC Slow Memory (8 KB).
  • ULP (Ultra-low-power) Coprocessor: A low-power microcontroller built into the chip that can run simple tasks while the main CPU is in deep sleep mode.

The current consumption in Deep-sleep therefore depends entirely on which of these components are left enabled to wake up the CPU. It usually ranges from 10 µA to 150 µA, which is extremely low compared to other modes.

esp32 deep sleep functional block diagram

There are four kinds of wake-up sources that can bring the ESP32 out of Deep-sleep:

Timer Wake-up

The first is Timer Wake-up, which uses only the RTC Controller and the RTC Timer to wake the chip after a certain amount of time has passed. In this case, the ESP32 uses about 10 µA of current.

External Wake-up (Ext0 vs. Ext1)

The second source is External Wake-up, which relies on special pins called RTC GPIOs that stay powered while the rest of the chip sleeps. External Wake-up comes in two forms: Ext0 and Ext1.

  • Ext0: uses only one RTC GPIO pin to wake the device (for example, a single button press) and typically consumes around 50 µA to 100 µA.
  • Ext1: can monitor several RTC GPIO pins simultaneously (for example, several buttons arranged in a keypad), and since it is controlled completely by the RTC Controller, it uses only around 10 µA, which makes it more power-efficient than Ext0.

Touch Wake-up

Another wake-up source is Touch Wake-up, where the ESP32 wakes when one of its capacitive touch pins is touched. In this case, the current consumption is around 30 µA.

ULP Sensor-Monitored Pattern

In this mode, the main CPU is off while the ULP co-processor remains active. It wakes up periodically, reads a sensor (using ADC or I2C communication), and then returns to sleep again. It only wakes the main CPU when a specific condition is met, for instance, when a sensor value crosses a threshold. In this case, the average current is about 100 µA. This pattern is ideal for battery-powered IoT applications that require periodic sensor readings without constantly running the power-hungry main CPU, which dramatically saves power.

The table below summarizes the power consumption in different Deep-sleep configurations:

Wake up SourceTypical Current
Timer Only6 – 10 µA
Ext0 Wake-up50 – 100 µA
Ext1 Wake-up10 µA
ULP Sensor-Monitored Pattern100 µA @1% duty
Touch Wake-up30 µA

Wake-up Latency and Deep-sleep Wake Stub

There’s one significant trade-off to be aware of with Deep-sleep mode. Because the system RAM is powered down during Deep-sleep, all the data that was stored there is lost. This means waking up from Deep-sleep is structurally similar to a full system reset. The chip must go through a complete boot sequence—loading the bootloader from ROM, verifying the flash memory, and initializing the runtime environment—which significantly impacts the wake-up latency, typically extending it to 200 ms to 500 ms.

However, this wake-up latency can be optimized using the “Deep-sleep wake stub”. This is a small function stored in RTC Fast Memory that runs immediately when the chip wakes up, even before the bootloader or any normal firmware code runs. This allows you to perform quick, time-critical tasks right after waking up.

Because the RTC memory stays powered during Deep-sleep, any data stored in it remains safe even while the rest of the chip is turned off. This allows the ESP32 to remember important information from before it went to sleep, so that when it wakes up it can continue running without losing progress.

For example, a weather station that sends temperature readings once an hour could store the last reading number in RTC memory. After waking up, the ESP32 can read that number and immediately continue with the next reading instead of starting the count over from zero.

If you want to learn more about how to configure ESP32 Deep Sleep mode and utilize its various wake-up sources in your projects, please visit our in-depth tutorial below.

ESP32 Hibernation mode

Hibernation Mode is the most power-saving sleep state available on the ESP32. It is designed for situations where the ESP32 will remain unused for a very long time or only needs to wake up once in a while. This makes it ideal for battery-powered systems that must last for months or even years without being recharged.

In Hibernation, the ESP32 shuts down even more parts of the chip than it does in Deep-sleep. Just like in Deep-sleep, the CPU cores, the system RAM, and all digital peripherals are turned off. However, Hibernation goes further by also disabling the internal 8 MHz oscillator, the ULP coprocessor, and the entire RTC Memory. This means that almost nothing remains powered inside the ESP32 during Hibernation.

esp32 hibernation mode functional block diagram

The only part that stays active is a single RTC timer that runs on the slow clock. This timer is responsible for waking the ESP32 when the programmed time is reached. Because almost everything else inside the chip is powered off, the ESP32 uses only about 5 µA.

There is one very important difference between Hibernation and Deep-sleep. Since RTC Memory is powered down in Hibernation, the ESP32 cannot keep any stored variables in memory. This means when the ESP32 wakes up from Hibernation, it’s essentially starting completely fresh, with no memory of what it was doing before it went to sleep. This makes Hibernation ideal for situations where you simply need the chip to wake up at a scheduled time and perform a task from scratch.

Shreepad Prabhu

Shreepad Prabhu

Shreepad is a passionate Electronics & Telecommunication Engineer with a deep love for embedded systems. He has over 15 years of experience, including his time as a Senior Embedded Engineer at Micromax contributing to solutions for Thermo Fisher Scientific, Tata Motors, Liebherr, and John Deere. Since co-founding Last Minute Engineers in 2018, he has written hundreds of articles and guides for Last Minute Engineers to help makers build with confidence. You can find him on LinkedIn