2N2222 Transistor

A general-purpose NPN bipolar transistor rated to 40 V and 600 mA, used to switch small loads or amplify low-power signals.

2N2222 Transistor: NPN bipolar transistor

What is the 2N2222 Transistor?

The 2N2222 is one of the most widely used NPN bipolar junction transistors. It works as an electronically controlled switch or amplifier: a small current into the base controls a much larger current flowing from collector to emitter. ON Semiconductor's common TO-92 version (P2N2222A) is rated for a 40 V collector-emitter voltage (VCEO) and up to 600 mA of continuous collector current.

Used as a switch, a logic-level signal fed through a base resistor drives the transistor into saturation so it can sink loads such as LEDs, small relays, and buzzers that a microcontroller pin cannot drive directly. Its DC current gain (hFE) runs roughly 100 to 300 at 150 mA, so a few milliamps of base current can control hundreds of milliamps at the collector.

Used as an amplifier, its 300 MHz transition frequency and low noise suit audio and low-RF stages. It is a small-signal part, with total dissipation around 625 mW at room temperature, so it is not intended for high-power or high-voltage loads.

2N2222 Transistor pinout

PinFunctionType
E EmitterPassivePassive
B BaseAnalogDigital input
C CollectorPassivePassive

Specifications

Dimensions
4.5 × 4.5 × 3.5 mm

Verified from the Tinkered component library.

Circuit requirements

  • Wire it as a low-side (common-emitter) switch: emitter to ground, the load between the positive supply and the collector, and the base driven high through a series resistor.
  • Always use a base current-limiting resistor. Driving the base straight from a 5 V logic pin can exceed the base current rating and overload the driving pin; roughly 1 kOhm gives a few milliamps of base drive.
  • To switch hard, overdrive the base so the transistor saturates. VCE(sat) is about 0.3 V at 150 mA with 15 mA of base current (a forced gain near 10). Under-driving leaves it in the active region where it dissipates extra heat.
  • Stay within ratings: 40 V maximum collector-emitter and 600 mA continuous collector current. It is a small-signal device, not a power transistor.
  • When switching an inductive load (relay, motor, solenoid), add a flyback diode across the load so the turn-off voltage spike does not exceed the 40 V rating.
  • Confirm the pinout against the datasheet before wiring. The TO-92 P2N2222A is arranged Emitter-Base-Collector from the flat face, which differs from the original metal-can 2N2222 and from lookalike TO-92 parts.

Common 2N2222 Transistor mistakes

No base resistor

Connecting a microcontroller pin straight to the base lets excessive base current flow, which can damage the pin and push the transistor past its base ratings. Always include a series resistor (about 1 kOhm for 5 V logic).

Guessing the pin order

The P2N2222A in TO-92 is Emitter-Base-Collector from the flat face, but the metal-can 2N2222 and other TO-92 parts like the BC547 use different orderings. Swapping collector and emitter stops it from switching, so check the datasheet.

Treating it like a power transistor

It handles at most 600 mA and 40 V with around 625 mW of dissipation. Larger motors, high-current LED strips, or higher-voltage loads need a MOSFET or a dedicated power transistor instead.

Under-driving the base

Relying on the full current gain leaves the transistor only partly on, dropping a volt or more and heating up. Provide enough base current (a forced gain of roughly 10 to 20) so VCE(sat) stays low.

No flyback diode on coils

Relays, motors, and solenoids produce a reverse voltage spike at turn-off that can exceed the 40 V rating and destroy the transistor. Add a diode (such as a 1N4148 or 1N4007) across the inductive load.

Popular 2N2222 Transistor projects

Relay or small-motor driver

A logic pin plus a base resistor and a flyback diode lets a 2N2222 turn a 5 V relay or a small DC motor on and off. This is the canonical first transistor-as-switch circuit.

Two-transistor LED blinker

A pair of 2N2222s with RC timing forms the classic astable multivibrator that flashes two LEDs alternately, a staple of introductory electronics courses.

Build with the 2N2222 Transistor.

Drop the 2N2222 Transistor into a circuit, write firmware, and simulate it in your browser, then deploy to real hardware. All in one editable Tinkered project.