Is there a formula to figure out the appropriate flyback diode rating vs the current flowing through a relay? Maybe I'm asking the wrong question and it's only a voltage consideration.


2 Answers 2


The diode will have to withstand the full operating voltage of the relay (since it will be anti-parallel to it) and also the full operating current since this current will flow through the diode when the relay turns off. This is because the current through an inductor can't change instantaneously (dI/dt is proportional to the voltage across the inductor), which means that once the controlling transistor switches off, the full relay current has to go somewhere.

If you want the relay to turn off faster, you'll have to increase the voltage across it during turn-off, which you can do with an additional Zener diode in series with the flyback diode. That way the current through the relay's coil decays faster. Of course this means that the driver (i.e. transistor) driving the relay has to withstand this higher voltage.

The power rating of the diode most likely won't matter as you're not going to switch the relay at a high enough frequency to dissipate substantial power in the diode. If you want to calculate it anyway, the formula for the diode's power dissipation is P = 1/2 I²Lf, where I is the relay current, L the relay's inductance, and f the frequency at which you switch the relay on and off.

  • 1
    \$\begingroup\$ I appreciate your response and would up vote the answer if I had enough reputation points to do so. \$\endgroup\$
    – Mitchell
    Commented May 22, 2021 at 0:37
  • \$\begingroup\$ @Jonathan S, but we usually use Schottky diodes for the flyback, not Zenors: (1) raspberrypi.org/forums/… (2) raspberrypi.org/forums/… \$\endgroup\$
    – tlfong01
    Commented May 22, 2021 at 1:58
  • \$\begingroup\$ But if you use zeners/TVS as flyback diodes, you will have to put another regular diode in series. Otherwise the Zener will forward conduct, shunting the load. Probably you meant to suggest the Zener in addition, but your post does not emphasize this enough, Imo. \$\endgroup\$
    – tobalt
    Commented May 22, 2021 at 8:00
  • \$\begingroup\$ @tobalt You're right, I've added that! \$\endgroup\$ Commented May 22, 2021 at 10:14
  • 1
    \$\begingroup\$ @tobalt I don't understand. At switch off, the coil will push the collector voltage of the driver transistor up to the supply voltage + 0.7 V roughly, or 0.7 V + V_z if Jonathan S.' zener is applied. \$\endgroup\$
    – HarryH
    Commented May 22, 2021 at 16:11

If you accidentally choose a diode with a lower current rating than the inductor current, you will usually get away with it. Diodes, especially cheap silicon diodes, tend to be 'as tough as old boots' and have a surge current rating orders of magnitude higher than their continuous rating (because they have to survive the switch-on surge into a big reservoir capacitor when used as a bridge rectifier). For instance, a 1 amp 1N400x diode can take a 8 ms surge of 30 A, the 3 A 1N540x will take 200 A, even a 100 mA 1N4148 is rated for a 4 A surge.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.