Transistor Base Resistor Calculator — BJT as a switch

Size the base resistor to drive a BJT into hard saturation, using forced beta rather than the datasheet's optimistic hFE.

Example: Switching 100 mA from a 3.3 V control pin at a forced beta of 15 needs a 375 Ω base resistor — use 360 Ω.

Formula

I_b = I_c / β_forced    R_b = (V_control − V_be) / I_b

Worked example

Switching 100 mA from a 3.3 V control pin at a forced beta of 15 needs a 375 Ω base resistor — use 360 Ω.

  1. I_b = I_c / β_forced

    100 mA / 15

    6.667 mA

    Forced beta, deliberately far below the datasheet hFE, to guarantee saturation.

  2. R_b = (V_control − V_BE) / I_b

    (3.3 V − 800 mV) / 6.667 mA

    375 Ω

Frequently asked questions

How do I calculate a base resistor for a transistor switch?

Pick a forced beta of 10 to 20, divide the collector current by it to get base current, then R_b = (V_control − V_BE) / I_b. Switching 100 mA from a 3.3 V pin at a forced beta of 15 gives about 375 Ω, so 360 Ω from E24.

Why not use the hFE from the datasheet?

hFE is a typical active-region figure with enormous part-to-part spread, and it falls at higher currents. Designing to it gives just enough base current to bring the transistor to the edge of saturation, where V_CE stays high and it dissipates far more than it should.

What is forced beta?

The ratio of collector to base current you deliberately design for, well below the transistor's actual capability. Forcing extra base current in guarantees saturation across temperature and part variation. 10 to 20 is the usual range.

My transistor gets hot — what did I get wrong?

Almost certainly too little base current. A saturated BJT drops about 0.2 V, so 100 mA should dissipate around 20 mW. If it is hot, V_CE is high, which means it is in the active region rather than saturated. Lower the base resistor.

Related tools