Decoupling capacitors: how many, what value, where

Missing or misplaced decoupling rarely stops a board outright. It shows up as random resets, Wi-Fi brownouts, noisy ADC readings and USB that drops out. The vendor rules are simple; following them on every pin is the hard part.

What decoupling capacitors do

A digital IC draws current in short spikes every time its logic switches. The regulator is centimetres away, behind trace and via inductance, so it cannot respond in nanoseconds. A small ceramic capacitor right at the power pin supplies those spikes locally and keeps the supply stable. Analog Devices' MT-101 tutorial puts it plainly: high-frequency supply noise is best reduced with low-inductance surface-mount ceramic capacitors connected directly to the IC's supply pins, while larger capacitors act as charge reservoirs for lower-frequency transients.

So decoupling has two layers:

  • Local, high-frequency: about 100 nF ceramic per power pin, as close to the pin as possible.
  • Bulk: a few microfarads to tens of microfarads per rail, near where the rail enters the board or the IC, to cover load steps such as a Wi-Fi transmit burst.

What the vendors ask for

PartRecommendation (from the vendor documents below)
STM32F1 / STM32F4One 100 nF ceramic per VDD pin, plus one 4.7 µF minimum (typically 10 µF) for the package. VDDA: 100 nF ceramic + 1 µF. VBAT without a battery: to VDD with 100 nF.
ESP32 family0.1 µF close to the digital supply pins, 10 µF on the analog supply rail, and at least 10 µF at the main power entrance (Espressif recommends an ESD diode there too).
RP2040100 nF per power pin; 1 µF close to both the input and the output of the internal core regulator.

Modules such as ESP32-WROOM include decoupling for the chip inside the can, but their datasheets still show external capacitors on the module's 3V3 pin. Treat the module as one big IC that still needs a bulk capacitor and a local 100 nF.

Placement matters more than value

A 100 nF capacitor 2 cm away, connected through thin traces and two vias, adds enough inductance to lose most of its high-frequency benefit. In practice:

  • Place each capacitor next to its pin, on the same side if possible, with short, wide connections.
  • Route the supply through the capacitor pad to the pin, and drop to the ground plane with a via right at the capacitor's ground pad.
  • Give each pin its own capacitor. Two pins on opposite sides of a QFN cannot share one.
  • Keep the loop formed by pin, capacitor and ground as small as you can: that loop area is the inductance you are fighting.

Choosing the capacitor

  • Dielectric: X7R or X5R for decoupling. Avoid Y5V/Z5U, whose capacitance collapses with temperature and voltage.
  • DC bias: ceramic capacitors lose capacitance as the applied voltage rises, and small packages lose the most. A 10 µF part in a tiny package at 3.3 V may deliver a fraction of its label value. Check the manufacturer's DC-bias curve, or choose a larger package or higher voltage rating.
  • Voltage rating: leave margin, especially on 5 V and VBUS rails that see hot-plug transients.
  • Regulators have their own rules: many LDOs need a minimum output capacitance and an ESR range for stability. That is a separate check from IC decoupling - follow the regulator datasheet.

Supplies people forget

  • VDDA / AVDD: the analog supply of an MCU. Needs its own capacitors (often behind a ferrite bead) and must be connected even if you never use the ADC.
  • VCAP: on STM32F4/F7/H7 this is the output of the internal core regulator, not a supply input. It needs its specified low-ESR capacitor and must never be connected to 3.3 V. See the STM32 guide.
  • VBAT and backup domains: tie to VDD with 100 nF if there is no battery.
  • Addressable LEDs: WS2812-class LEDs switch current constantly; their datasheets ask for a capacitor per package, and long strips also need bulk capacitance at the injection points.
  • Crystal oscillators and USB PHYs: every IC with a power pin needs decoupling, including small ones.

How the checker counts decoupling

The decoupling rule finds every supply net that feeds an IC power pin and counts capacitors from that net to ground. A supply with IC power pins and no capacitor is an error when an MCU is on it, a warning otherwise. Fewer capacitors than power pins is a warning, or a note when at least half the pins are covered, because adjacent pins can sometimes share. A separate bulk capacitance rule looks for a microfarad-class capacitor on regulator inputs and outputs and on MCU supplies.

What it cannot see: placement, trace width, via count and dielectric. A netlist does not contain them. Those are exactly the items a layout review covers.

Quick checklist

  1. Count power pins per IC; place the same number of 100 nF capacitors.
  2. Add 4.7-10 µF bulk per rail and at every regulator input and output.
  3. Decouple VDDA separately; never connect VCAP to a supply.
  4. Place capacitors at the pins with a direct via to ground.
  5. Check DC-bias derating for the larger ceramics.

Primary sources