Parts
IRF540N MOSFET: pinout, ratings, 5 V gate drive and the IRF9540N
By Bulan Sarkar
The IRF540N is G-D-S: with the printed face toward you and the leads down, gate, drain and source run left to right, and the metal tab is also the drain. It is a 100 V, 33 A N-channel MOSFET in a TO-220 with at most 44 mΩ on-resistance, but only with 10 V on the gate. The threshold can be as high as 4 V, so a 5 V Arduino pin drives it with no guarantee and a 3.3 V pin leaves it off.
This page reads Infineon's IRF540NPbF data sheet (Rev. 2.1) and, for the P-channel IRF9540N, the International Rectifier sheet Infineon still hosts. It works through a 12 V, 5 A heater at 10 V, 5 V and 3.3 V on the gate, with the heat and the heatsink each case needs, then switches the positive side with an IRF9540N.
Pinout by package
Printed face toward you, leads down: gate, drain, source from left to right. The tab is the drain.
The tab is the drain. On a shared or grounded heatsink it needs an insulating pad.
Source: Infineon IRF540NPbF data sheet, p. 1 (symbol labelled Gate pin 1, Drain pin 2 and tab, Source pin 3; G D S table); Infineon IRF540NPbF data sheet, p. 8 (TO-220 outline with leads numbered 1, 2, 3)
Printed face toward you, leads down: gate, drain, source from left to right. The tab is the drain.
P-channel: the source goes to the positive rail and the gate is pulled below it to turn on.
Source: Infineon (International Rectifier) IRF9540NPbF data sheet, PD-94790A, p. 8 (TO-220AB lead assignments: 1 gate, 2 drain, 3 source, 4 (tab) drain)
Which one do you have?
Read the print on the face. IRF540N is an Infineon part number, from the International Rectifier range Infineon bought; PbF only means lead-free. The IRF540 with no N is a different part from other makers' ranges, so the figures on this page are for the IRF540N only. The IRF9540N is the P-channel part of the same family, with the same pins.
A good IRF540N meters like the test further down and carries a maker's logo and a date code. If a part runs hot at a load far below its rating, check the gate voltage before you suspect a fake.
Absolute maximum ratings
Both parts take 100 V and ±20 V on the gate. The IRF540N is rated 33 A and 130 W, the IRF9540N 23 A and 140 W, all with the case held at 25 °C. The IRF9540N's voltages and currents are negative on its sheet; the table gives magnitudes.
| Parameter | IRF540NTO-220 | IRF9540NTO-220 |
|---|---|---|
| Drain-source voltage VDS | 100 V | 100 V (−100 V) |
| Gate-source voltage, max VGS | ±20 V | ±20 V |
| Continuous drain current IDcase at 25 °C, VGS 10 V | 33 A | 23 A |
| Continuous drain current IDcase at 100 °C, VGS 10 V | 23 A | 16 A |
| Pulsed drain current IDM | 110 A | 76 A |
| Power dissipation PDcase held at 25 °C, not free air | 130 W | 140 W |
| Avalanche current IAR | 16 A | 11 A |
| Junction to case, max RthJC | 1.15 °C/W | 1.1 °C/W |
| Case to sink, typical RthCSflat, greased surface | 0.50 °C/W | 0.50 °C/W |
| Junction to air, max RthJAno heatsink | 62 °C/W | 62 °C/W |
| Junction temperature TJ | −55 to +175 °C | −55 to +175 °C |
The 33 A needs the case held at 25 °C, which no real heatsink does. In free air the part has 62 °C/W from junction to air. At 10 V on the gate, with the on-resistance multiplied by 1.5 for a warm die, about 3.8 A keeps the junction 60 °C above the room with no heatsink. Past that it needs one.
Characteristics: low resistance, at one gate voltage
| Parameter | IRF540NTO-220 | IRF9540NTO-220 |
|---|---|---|
| Gate threshold voltage VGS(th)VDS = VGS, ID = 250 µA | 2.0 to 4.0 V | 2.0 to 4.0 V (negative) |
| On-resistance, max RDS(on)VGS = 10 V (ID 16 A / 11 A) | 44 mΩ | 117 mΩ |
| On-resistance at 5 V or 4.5 V gate RDS(on) | not specified | not specified |
| Forward transconductance, min gfsVDS = 50 V (ID 16 A / 11 A) | 21 S | 5.3 S |
| Total gate charge, max QgVGS = 10 V, VDS = 80 V (ID 16 A / 11 A) | 71 nC | 97 nC |
| Input capacitance, typical CissVGS = 0 V, VDS = 25 V, 1 MHz | 1960 pF | 1300 pF |
| Drain current, typical IDVGS = 5 V, VDS = 50 V, 25 °C (Fig. 3, read by us) | about 28 A | not read |
| Body diode forward voltage, max VSDTJ = 25 °C (IS 16 A / 11 A) | 1.2 V | 1.6 V |
| Body diode reverse recovery, typ / max trrdI/dt = 100 A/µs | 115 / 170 ns | 150 / 220 ns |
The on-resistance row is the one to read. Infineon gives 44 mΩ at 10 V on the gate and nothing lower. The threshold, 2.0 to 4 V, is where the part passes just 250 µA, so it says when the part starts to turn on, not when it is fully on.
The typical curve shows what a 5 V gate can do. Infineon's Fig. 3 plots drain current against gate voltage for a typical part with 50 V across it: about 12 A at 4.5 V, about 28 A at 5 V and about 95 A at 7 V. That is far more than the IRF520 passes at 5 V (about 2 A on Vishay's curve), which is why an IRF540N on a 5 V pin often seems to work. A part at the 4 V threshold limit sits further right and passes about 9.4 A at 5 V.
What it is good for
- Low-side switching of heaters, lamps, motors and LED strips from a few amps up to tens of amps, when something drives the gate to 10 V or more and the part sits on a heatsink.
- 24 V and 48 V loads. At 100 V it has more headroom than the 55 V logic-level parts.
- With the IRF9540N, switching the positive side of a 12 V or 24 V load, or an H-bridge whose gates get a proper driver.
On a microcontroller pin with no driver it is a gamble on the threshold. For that, see IRFZ44N vs IRLZ44N and our guide to choosing a MOSFET for Arduino and ESP32.
Worked example: a 12 V, 60 W heater at 10 V, 5 V and 3.3 V on the gate
A 12 V, 60 W heater measures 2.4 Ω and draws 5 A. The IRF540N switches its low side: source to ground, heater between +12 V and the drain. The gate is fed through 220 Ω, with 10 kΩ to ground on the drive side so the gate stays off while the pin floats at reset. A heater is resistive, so it needs no flyback diode; a motor or solenoid in its place does.
1. At 10 V on the gate (guaranteed). The data sheet promises at most 44 mΩ. 5 A × 5 A × 0.044 Ω = 1.10 W of heat. On-resistance rises as the die warms, so we multiply by 1.5, the margin our MOSFET guide uses: 1.65 W. With no heatsink, 1.65 W × 62 °C/W = 102 °C above the room, about 142 °C (288 °F) at the junction in a 40 °C (104 °F) room. That is under the 175 °C rating but far too hot to touch, so give it a heatsink. To hold the rise to 60 °C, the whole path may have 60 ÷ 1.65 = 36.4 °C/W. Take away 1.15 °C/W junction to case and 0.5 °C/W for a greased pad, and the heatsink must be 35 °C/W or better.
2. At 5 V on the gate, a typical part (no guarantee). The data sheet has no row here, so we fitted a curve to Infineon's typical Fig. 3: drain current = 9.36 A/V² × (VGS − 3.29 V)², with a series resistance that makes it 44 mΩ at 10 V. At 5 V that part could pass up to 27.4 A; carrying 5 A it drops about 0.34 V. That is 1.72 W, or 107 °C above the room, about 147 °C at the junction with no heatsink. It works, and it runs hotter than case 1 even after case 1's warm-die margin.
3. At 5 V, a part at the 4 V threshold limit. Move the same curve right to a 4 V threshold. At 5 V the part can now pass only 9.4 A, so it still carries the 5 A, but it drops 0.50 V doing so: 2.49 W. With no heatsink that is 154 °C above the room, about 194 °C at the junction, past the 175 °C rating. A heatsink of 22 °C/W or better holds it to a 60 °C rise, but nothing printed on the part tells you which threshold you got.
4. At 3.3 V. Our fit puts a typical part's turn-on at 3.29 V, so at 3.3 V it passes about 0.9 mA, essentially nothing, and Infineon's Fig. 3 starts at 4.5 V. Use a driver or a part rated at 2.5 V on the gate.
The gate drive lesson covers ways to get 10 V onto the gate from a logic pin, and transistor packages and heat explains the °C/W arithmetic.
Worked example in numbers
- 10 V gate, 5 A
- 1.65 W
- Heatsink for a 60 °C rise
- 35 °C/W
- No heatsink, 10 V gate
- 3.8 A
- 5 V gate, high threshold
- 2.49 W
IRF9540N: switching the positive side
The IRF9540N is the P-channel part: source to the positive rail, load from the drain to ground, and it turns on when the gate is pulled below the source. Its sheet gives 117 mΩ at most with the gate 10 V below the source, and a threshold of 2.0 to 4 V below it. On a 12 V rail the simplest drive is a small NPN that pulls the gate to 0 V, which puts it 12 V below the source, inside the ±20 V rating.
The numbers: 2 A × 2 A × 0.117 Ω = 0.47 W, times 1.5 for a warm die is 0.70 W, and × 62 °C/W is 44 °C above the room, about 84 °C at the junction with no heatsink. The pin gives the BC547 about 4.3 mA of base current through 1 kΩ, and the BC547 only has to sink 1.2 mA from the pull-up. Switching off is slow: the 10 kΩ has to charge up to 97 nC of gate, so keep this circuit for on and off, not fast PWM. On a rail above 20 V, add a resistor divider or a zener so the gate never sees more than 20 V.
Tips and checks
- Measure drain to source with the load running. About 0.2 V at 5 A is right at a 10 V gate; half a volt or more means the gate is not driven hard enough.
- Plan the heatsink from the watts, not the 33 A. Above about 3.8 A the bare TO-220 runs past a 60 °C rise.
- Keep the 10 kΩ pull-down. A floating gate can leave the part half on, and half on is where it gets hottest.
- The tab is the drain. On a grounded heatsink it shorts the load: use an insulating pad and shoulder washer, then meter tab to heatsink for an open circuit.
- For PWM, the gate charge matters. Up to 71 nC through 220 Ω is fine at a few hundred hertz; at tens of kilohertz use a gate driver.
Substitutes
Where a 5 V pin drives the gate and the load runs from 55 V or less, the IRLZ44N in the same footprint is the fix. The IRF520N fits the same holes but is a much smaller part.
| Part | Pins | Verdict |
|---|---|---|
| IRF9540N (P-channel partner) | G-D-S | Not a replacement: the P-channel part of the same voltage class, for switching the positive side. Same pins and ±20 V gate, 117 mΩ at −10 V.Infineon (International Rectifier) IRF9540NPbF data sheet, PD-94790A, p. 1; Infineon (International Rectifier) IRF9540NPbF data sheet, PD-94790A, p. 2 |
| IRF520N | G-D-S | Same pins and 100 V, but a smaller die: 9.7 A and 0.20 Ω at a 10 V gate. Fine where the load is under about 1.5 A; otherwise a step down.Infineon IRF520NPbF data sheet, p. 1; Infineon IRF520NPbF data sheet, p. 2 |
| IRLZ44N | G-D-S | The fix for a 5 V pin, if the load runs from 55 V or less: on-resistance guaranteed at 5 V (25 mΩ) and 4 V. Its gate only takes ±16 V.Infineon (International Rectifier) IRLZ44NPbF data sheet, PD-94831, p. 1; Infineon (International Rectifier) IRLZ44NPbF data sheet, PD-94831, p. 2; Infineon (International Rectifier) IRLZ44NPbF data sheet, PD-94831, p. 8 |
Checking one with a multimeter
- Short all three leads together for a moment to empty the gate. Set the meter to diode test.
- IRF540N: red probe on the source, black on the drain, and the body diode reads about 0.4 to 0.7 V. Reversed, it should read open. For the IRF9540N, swap the probes.
- IRF540N: touch the red probe to the gate with the black on the source for a second. Now red on the drain, black on the source: a good part conducts. Short gate to source and it goes open again.
- If step 3 shows nothing, your meter's test voltage may be below the threshold. That is the same problem as the 3.3 V pin, not a dead part.
The transistor testing lesson and continuity and diode test explain what the meter is doing.
What we'd do
Use the IRF540N where the gate gets 10 V or more and the load is several amps or more, on a heatsink sized from the watts. For a 5 V Arduino pin and a load under 55 V, fit an IRLZ44N instead, whose data sheet covers that gate voltage. For the positive side of a 12 V load, an IRF9540N with a BC547 pulling its gate down is simple and runs cool at 2 A.
Questions people ask
What is the IRF540N pinout?
Gate, drain, source from left to right with the printed face toward you and the leads down. The metal tab is connected to the drain. The IRF9540N is the same.
Can an Arduino drive an IRF540N directly?
A typical part works from a 5 V pin, but nothing on the data sheet guarantees it: the on-resistance is only given at 10 V and the threshold can be 4 V. At 5 A a high-threshold part dissipates about 2.49 W and overheats without a heatsink.
Does the IRF540N work with an ESP32?
No. At 3.3 V on the gate a typical IRF540N is barely at its threshold. Use a logic-level MOSFET rated at 2.5 V, or a driver stage that raises the gate voltage.
How much current can an IRF540N switch?
The 33 A rating needs the case held at 25 °C. Without a heatsink, at 10 V on the gate, about 3.8 A keeps the junction 60 °C above the room. A 5 A load needs a heatsink of about 35 °C/W or better.
What is the difference between the IRF540N and the IRF9540N?
The IRF540N is N-channel and switches the low side; the IRF9540N is P-channel and switches the high side. Same pins, same 100 V, but the IRF9540N has 117 mΩ against 44 mΩ.
Buying the IRF540N in India
The IRF540N is stocked by most Indian electronics shops and online sellers, usually beside the IRFZ44N. Check the print for IRF540N and a maker's logo, and meter a part before it goes on a board. If the job is a 5 V Arduino project, buy the IRLZ44N instead. Our guide to buying electronic components in India compares ten online sellers and covers how to spot fakes.
One email a month from the bench
New circuits, lessons, part guides and calculators, on the first Sunday of each month.
Used in these lessons
Lessons that go deeper
Datasheets this page was checked against
- Infineon, IRF540NPbF data sheet (Rev. 2.1, 2026-07-24)
- Infineon (International Rectifier), IRF9540NPbF data sheet, PD-94790A (dated 01/23/04)
- Infineon, IRF520NPbF data sheet (Rev. 2.1, 2026-07-24)
- Infineon (International Rectifier), IRLZ44NPbF data sheet, PD-94831 (dated 11/11/03)
Makers revise datasheets. If the copy you download has a newer revision and a number here disagrees with it, the datasheet wins, and we would like to hear about it.