NPN Transistor Switch: Circuit, Measurements and Online Simulator

To build this NPN Transistor Switch circuit you need a 9 V battery, a toggle switch, a 10 kΩ resistor, a digital multimeter, a 2N2222 NPN transistor, a 330 Ω resistor and a green LED. A toggle switch feeds 10 kΩ into the base of a 2N2222; the transistor switches a 20 mA LED on the collector. The ammeter shows how little base current it takes. Make the 8 connections in the wiring table, press Run, and then flip the switch. The multimeter (in series with the base) reads ≈ 0.8 mA while the LED takes ≈ 20 mA: a current gain of ~25 in saturation.

Open this circuit in the free Electronics bench simulator

Parts list

QtyPartWhat it does
19 V batteryA DC source with a little internal resistance. + is the longer terminal.
1Toggle SwitchAn on/off switch between its two terminals. Flip it while the circuit runs.
110 kΩ resistorLimits current. 220 Ω in series with an LED; 10 kΩ as a pull-up or pull-down.
1Digital MultimeterTurn the dial: V (across a part, COM and V), A (in series, COM and A), Ω / continuity / diode (on an unpowered part), Hz. The A range has a 10 A fuse — put it across a supply and it blows.
12N2222 NPN transistorA small base current (B→E) lets a current β times larger flow C→E. Use a base resistor (1 kΩ from a pin) to switch loads.
1330 Ω resistorLimits current. 220 Ω in series with an LED; 10 kΩ as a pull-up or pull-down.
1green LEDLights when A (anode, the bent leg) is high and C (cathode) is low. Use a resistor.

Wiring

#FromTo
19 V battery +Toggle Switch 1
2Toggle Switch 210 kΩ resistor leg 1
310 kΩ resistor leg 2Digital Multimeter A
4Digital Multimeter COM2N2222 NPN transistor B
59 V battery +330 Ω resistor leg 1
6330 Ω resistor leg 2green LED anode (A, long leg)
7green LED cathode (C, short leg)2N2222 NPN transistor C
82N2222 NPN transistor E9 V battery -

Step by step

  1. Open the electronics bench. Open the BitForBytes Embedded Lab in your browser. A circuit with no microcontroller runs on the analog bench: no install or account is needed.
  2. Add the parts. Add a 9 V battery, a toggle switch, a 10 kΩ resistor, a digital multimeter, a 2N2222 NPN transistor, a 330 Ω resistor and a green LED from the parts palette (Instruments, Power, Passive and Semiconductors).
  3. Wire 1. Connect 9 V battery + to Toggle Switch 1.
  4. Wire 2. Connect Toggle Switch 2 to 10 kΩ resistor leg 1.
  5. Wire 3. Connect 10 kΩ resistor leg 2 to Digital Multimeter A.
  6. Wire 4. Connect Digital Multimeter COM to 2N2222 NPN transistor B.
  7. Wire 5. Connect 9 V battery + to 330 Ω resistor leg 1.
  8. Wire 6. Connect 330 Ω resistor leg 2 to green LED anode (A, long leg).
  9. Wire 7. Connect green LED cathode (C, short leg) to 2N2222 NPN transistor C.
  10. Wire 8. Connect 2N2222 NPN transistor E to 9 V battery -.
  11. Run and measure. Press Run, then flip the switch. The multimeter (in series with the base) reads ≈ 0.8 mA while the LED takes ≈ 20 mA: a current gain of ~25 in saturation.

Lab sheet

// Electronics bench: NPN transistor as a switch
//
// Base current Ib = (9 V − 0.7 V) / 10 kΩ ≈ 0.83 mA.
// Collector: 9 V → 330 Ω → LED → C; emitter to 0 V.
// With Ib × β far more than the LED needs, the transistor saturates:
// Vce drops to ~0.1 V and the resistor alone sets the LED current.

What to try

Press Run, then flip the switch. The multimeter (in series with the base) reads ≈ 0.8 mA while the LED takes ≈ 20 mA: a current gain of ~25 in saturation.

Frequently asked questions

How do I wire the NPN Transistor Switch circuit?

Make 8 connections: 9 V battery + to Toggle Switch 1; Toggle Switch 2 to 10 kΩ resistor leg 1; 10 kΩ resistor leg 2 to Digital Multimeter A; Digital Multimeter COM to 2N2222 NPN transistor B; 9 V battery + to 330 Ω resistor leg 1; 330 Ω resistor leg 2 to green LED anode (A, long leg); green LED cathode (C, short leg) to 2N2222 NPN transistor C; 2N2222 NPN transistor E to 9 V battery -.

What parts do I need for the NPN Transistor Switch?

A 9 V battery, a toggle switch, a 10 kΩ resistor, a digital multimeter, a 2N2222 NPN transistor, a 330 Ω resistor and a green LED.

Can I simulate the NPN Transistor Switch online for free?

Yes. The BitForBytes Embedded Lab solves the circuit in time, the way SPICE does (nodal analysis with real diode, transistor and capacitor models), and gives you a bench power supply, function generator, oscilloscope and multimeter to measure it — free, in the browser.

What does this circuit show?

A toggle switch feeds 10 kΩ into the base of a 2N2222; the transistor switches a 20 mA LED on the collector. The ammeter shows how little base current it takes.

More Electronics bench projects