Anyone who has built a dimmable LED strip or lamp on an ESP32 with ESPHome has probably seen it: a fade looks smooth until the last few percent, then the light drops in visible steps before it goes out. On 1 November 2026, just before 1:00 Warsaw time, ESPHome merged a change by Jakub Sztandera (Kubuxu) that targets exactly that. The ledc output gets an optional dithering setting.
Why the steps appear
The LEDC peripheral dims an LED with PWM, and the duty cycle is a whole number of timer ticks. Gamma correction, which ESPHome applies so that brightness looks even to the eye, squeezes the bottom of the brightness range into very few of those ticks. At a high PWM frequency there are fewer ticks per period to begin with, so near zero the light can only jump between a handful of levels.
With dithering: true, ESPHome turns on a feature that the LEDC hardware already has: four extra fractional duty bits. The controller spreads these fractions across successive pulses, so the average duty can change in steps of 1/16 of a tick. The PWM frequency stays the same, which matters if you raised it to avoid flicker on camera or audible coil noise.
The configuration from the pull request looks like this:
output:
- platform: ledc
id: led_pwm
pin: GPIO4
frequency: 19531Hz
dithering: true
light:
- platform: monochromatic
name: LED
output: led_pwm
gamma_correct: 1.8
default_transition_length: 3s
Supported chips and caveats
The option covers the ESP32, ESP32-S2, ESP32-S3, ESP32-S31, ESP32-C2, ESP32-C3, ESP32-C5, ESP32-C6, ESP32-C61, ESP32-H2 and ESP32-P4. Only the ESP32-C3 has been tested on hardware, under both ESP-IDF and Arduino. The other variants were checked against their documented register layouts and compiled. ESP8266, RP2040 and the other platforms are not part of this change.
Dithering is off by default. When enabled, it stays active at steady brightness too, not only during transitions. The author warns that at very low PWM frequencies combined with low brightness, dithering itself can cause visible flicker, so it suits setups that already run at a fairly high frequency.
When it arrives
The change is in ESPHome's dev branch, with documentation in a separate pull request for esphome.io. The latest stable release is 2026.10.1 from 27 October, so the option should reach users with the next monthly release. If you want to try it earlier, the dev branch is the way, ideally on one test light first, especially on a chip other than the ESP32-C3.