Every transformer power supply starts with the same steps: a transformer that steps down the mains voltage, a bridge of diodes that rectifies the current, and then a large capacitor. Without that capacitor the output isn't true DC, but pulses that rise to the peak and fall to zero 100 times a second.
What exactly does the capacitor do?
The capacitor charges up to the peak of the wave, and once the wave starts falling, it feeds the load until the next peak. During that time its voltage drops a little, and that drop is called ripple.
The bigger the capacitor, the smaller the ripple. But an oversized capacitor means higher cost, more size and a huge charging current at switch-on.
The equation
C = I ÷ (f × ΔV)
- I: load current in amps
- ΔV: the allowed ripple in volts
- f: the ripple frequency, which depends on the type of rectifier:
| Rectifier type | Ripple frequency (50 Hz mains) |
|---|---|
| Half-wave (one diode) | 50 Hz |
| Full-wave (bridge of 4 diodes) | 100 Hz |
The bridge refills the capacitor twice as often, so it needs half the capacitance for the same ripple.
Example: a 12 V AC supply with a bridge, 1 A, 1 V of ripple
- C = 1 ÷ (100 × 1) = 0.01 F = 10,000 µF.
- With the same load on a single diode (half-wave): C = 1 ÷ (50 × 1) = 0.02 F, that is 20,000 µF, and the nearest standard value above it is 22,000 µF.
The real peak voltage
A transformer marked 12 V means 12 V RMS. The capacitor charges to the peak:
Vpeak = Vrms × 1.414 − diode drops
In a bridge the current passes through two diodes each half-cycle, about 0.7 V each:
- Vpeak = 12 × 1.414 − 1.4 ≈ 15.6 V.
So the "12 V" comes out at about 15.6 V DC with no load, which surprises a lot of people the first time they measure it.
The capacitor's voltage rating
Choose a capacitor rated at least 25% above the peak voltage. Here 15.6 × 1.25 ≈ 19.5 V, so the nearest standard rating is 25 V. And bear in mind that the mains voltage itself can rise above 220 V.
A complete example: a regulated 12 V supply with a 7812
You want a steady 12 V at 1 A. The 7812 regulator needs an input at least about 2.5 V above 12, so the lowest voltage after ripple must stay above 14.5 V.
Option one: a 12 V AC transformer
- Peak ≈ 15.6 V.
- For the lowest point to stay above 14.5, the ripple must be less than 1.1 V.
- C = 1 ÷ (100 × 1.1) ≈ 9100 µF → 10,000 µF.
- That's on the edge: any dip in the mains (which happens), and the voltage falls below the regulator's limit, and the output starts to ripple.
Option two: a 15 V AC transformer
- Peak ≈ 15 × 1.414 − 1.4 ≈ 19.8 V.
- You have 5 V of margin for ripple, so a 4700 µF capacitor is enough (ripple about 2.1 V, lowest point about 17.7 V).
- But the heat on the regulator is higher: the average input is about 18.7 V, so the heat ≈ (18.7 − 12) × 1 ≈ 6.7 W, and you need a large heatsink.
So there's always a trade-off between capacitor size and regulator heat. The transformer power supply design calculator makes that trade-off and gives you the transformer, capacitor and heat together, and the linear regulator heat calculator tells you how big a heatsink you need.
The voltage drops with load
An unregulated supply (just a transformer, bridge and capacitor) changes voltage with load for two reasons:
- The transformer itself: small transformers have a no-load voltage 10–20% above the rating, which is specified at full current. So a 12 V transformer may give 14 V AC with no load.
- Ripple: the more current, the more the capacitor discharges between peaks, so the average voltage falls.
So if you measure the supply with no load and find 18 V, don't worry; it'll come down when you connect the load. And if the circuit needs a steady voltage, a regulator after the capacitor is essential.
Inrush current
The moment you connect power, the capacitor is empty and behaves like a short, so it draws a huge current for a fraction of a second. With a 10,000 µF capacitor, that current can reach tens of amps, limited only by the resistance of the transformer winding and the wires. That's why:
- The input fuse must be a slow-blow (T) type, or it'll blow every time you switch on. Read the fuse article.
- The bridge must handle a high momentary current (surge current) stated in its datasheet. Choosing a bridge is in the rectifier and bridge article.
- Larger devices have an NTC thermistor on the input to limit that current.
Practical tips
- Ripple heats the capacitor: large capacitors can handle a specific ripple current stated in the datasheet. If the current is high, use several capacitors in parallel instead of one huge one.
- Heat shortens the capacitor's life: a rough rule is that an electrolytic's life doubles for every 10 °C cooler it runs. Keep it away from heatsinks and the transformer, and choose a 105 °C type. Symptoms of a capacitor at the end of its life are in the bulging capacitors article.
- A small capacitor beside the big one: a 100 nF ceramic in parallel with the electrolytic filters the high frequencies the electrolytic is weak at.
- If you really need a steady voltage: the capacitor reduces ripple but doesn't remove it, and the output voltage varies with load and with the mains. Put a regulator such as the LM317 or a 7805 after it.
- Safety: a large capacitor stays charged after you disconnect power. Discharge it through a resistor before touching the circuit, or fit a permanent bleeder resistor across it.
How do you measure ripple?
- An oscilloscope is the proper way: you'll see the waveform and the ripple exactly. Read the oscilloscope article.
- Roughly with a multimeter: set it to V~ (AC) and measure across the capacitor with the circuit running under load. The figure won't be exactly ΔV because the wave isn't sinusoidal, but the higher it is, the more ripple. Useful for comparing before and after changing the capacitor.
FAQ
Can I use two 4700 µF capacitors in parallel instead of 10,000? Yes, the capacitance adds up (9400 µF), and it also shares the ripple current between them, so each runs cooler.
Can I use a 63 V capacitor instead of 25 V with the same capacitance? Yes, a higher voltage rating does no harm. It's just bigger and more expensive.
Should I make the capacitor as big as possible for a cleaner output? Up to a point. A very large capacitor increases the inrush current and the stress on the bridge and transformer. Calculate the capacitance you need, and add a reasonable margin.
Calculate it in a second
The filter capacitor calculator works out the capacitance and the nearest standard value, the peak and DC voltages, and the right capacitor voltage rating, for half-wave and full-wave.