A 4-pin connector is a generic housing with four conductive contacts, and its function depends entirely on its mechanical standard, electrical rating, and specific pin assignment, not the pin count alone.
Plugging a 4-pin connector into the wrong socket can fry a component or simply fail to work. The number “4-pin” tells you nothing about voltage, signal type, or even if it’s meant for power or data. Identifying the correct connector type — by its pitch, keying, and locking mechanism — is the only way to get it right the first time. The table below breaks down the most common variants you’ll actually encounter.
| 4-Pin Connector Type | Typical Pitch | Primary Use |
|---|---|---|
| ATX CPU Power | 4.2mm | +12V power for PC processor |
| ATX Fan Header | 2.54mm | PWM fan control (+12V, GND, Tach, PWM) |
| JST XH | 2.5mm | Consumer electronics, battery packs |
| JST PH | 2.0mm | Compact mid-power devices |
| JST SH | 1.0mm | Drones, wearables (1A, 50V max) |
| M12 D-coded | Threaded | Industrial 100BASE-TX Ethernet |
| DIN 41524 | Circular, keyed | S-Video, CCTV power, modems |
| Deutsch DT04-4P | Locked wire-to-wire | Automotive, harsh environments |
Why Pin Count Alone Is a Trap
A 4-pin ATX CPU connector carries 12V power. A 4-pin DIN connector carries S-Video signals. A 4-pin JST SH carries 1A at 5V inside a drone. All use four contacts, but none are interchangeable. The physical housing shape, pitch (center-to-center distance between pins), and keying (molded ribs or asymmetrical shapes) prevent cross-mating — but only if you inspect them. The most common mistake is grabbing a 2.54mm fan header for a 4.2mm CPU power socket. The difference in pitch alone means the pins won’t seat properly, and forcing it damages both the connector and the device.
How to Identify a 4-Pin Connector Correctly
Identifying a 4-pin connector comes down to three checks performed in order: measure the pitch, inspect the keying, and note the locking mechanism.
Step 1: Use digital calipers to measure the center-to-center distance between two adjacent pins. A measurement of 2.54mm points to an ATX fan header or DIP socket. A 4.2mm pitch means ATX12V CPU power. A 2.5mm pitch is almost certainly JST XH. A 2.0mm pitch is JST PH, and 1.0mm is JST SH. The pitch alone narrows your search to one or two families.
Step 2: Check the housing for keying features — molded ribs, notches, or an asymmetrical shape that only allows connection one way. DIN connectors use a circular, keyed shell with a prominent notch. JST connectors use a small latch and a polarizing rib. M12 connectors rely on a threaded collar and coding (A-coded for sensors, D-coded for Ethernet). No keying visible often means a generic friction-lock header.
Step 3: Look at the locking mechanism. A plastic latch indicates JST XH or PH. A threaded nut means M8 or M12 industrial. A simple friction fit is typical of ATX fan headers. A positive-lock tab (like the Deutsch DT04) signals an automotive or robotics application where vibration resistance matters. If you’re wiring up a project and need a reliable 4 to 7 pin adapter for towing, our roundup of tested 4 to 7 pin adapters covers the options that hold up under real use.
How a 4-Pin Connector Communicates (PWM Fan Example)
The most familiar 4-pin connector to PC builders is the PWM fan header. Its pin assignment is standardized across virtually every motherboard: Pin 1 carries +12V, Pin 2 is Ground, Pin 3 outputs the tachometer signal (fan speed), and Pin 4 receives a 25 kHz PWM control signal from the motherboard. The motherboard modulates the duty cycle on Pin 4 to control fan speed, while the fan reports its RPM back on Pin 3. A 3-pin fan will also work in a 4-pin header — it simply runs at full speed or voltage-controlled speed, ignoring the PWM pin entirely. But a 4-pin fan in a 3-pin header loses all PWM control and runs at full speed, which is noisy but safe.
How to Verify Electrical Requirements Before Use
Before wiring or replacing any 4-pin connector, confirm two numbers: the device’s maximum current draw and the connector’s rated current. A JST SH connector is rated for 1A at 50V — fine for a drone flight controller, dangerous for a CCTV camera pulling 3A. A 4-pin DIN connector historically used for modems can handle about 3A at low voltage, but some circular 4-pin connectors found on 3D printer heated beds carry 110V. Cable Harness Assembly’s 4-pin guide provides a detailed reference on current ratings per connector family. Always consult the manufacturer’s datasheet for the exact part number, and never exceed 80% of the rated current for continuous loads.
| Connector Model | Key Specs | Best For |
|---|---|---|
| JST XH | 2.5mm pitch, latch lock, 3A typical | Battery packs, consumer PCBs |
| M12 D-coded | Threaded, IP67, 100BASE-TX | Industrial Ethernet, sensors |
| DIN 41524 | Circular, keyed, ~3A | S-Video, CCTV, legacy power |
| Deutsch DT04-4P | Automotive sealed, vibration-proof | Trailers, off-road, marine |
| Phidgets CBL4402_0 | IP68 waterproof, 3–8mm cable | Outdoor sensors, robotics |
4-Pin Connector: Two Common Traps to Avoid
Don’t assume an M12 4-pin handles gigabit Ethernet. M12 D-coded 4-pin is designed for 100BASE-TX (Fast Ethernet) only. Gigabit Ethernet over M12 requires X-coded 8-pin connectors. Plug a 4-pin D-coded cable into a gigabit device and you’ll cap out at 100 Mbps.
Never use a 4-pin DIN for MIDI. MIDI uses a 5-pin DIN connector with a 180-degree pin arrangement. A 4-pin DIN shell is keyed differently and physically will not mate with a 5-pin MIDI socket. If you’re building a MIDI cable, the 4-pin is the wrong part entirely — buy a proper 5-pin DIN.
Waterproofing is not optional outdoors. Standard JST and ATX headers have no IP rating. If your connector sits in rain, dust, or a washdown environment, you need an IP67 or IP68 circular connector like the Phidgets CBL4402_0. A non-sealed connector in a wet location will corrode within weeks.
FAQs
Can I plug a 4-pin fan into a 3-pin motherboard header?
Yes. A 4-pin PWM fan will run at full speed when plugged into a 3-pin header, because the motherboard lacks the fourth PWM control pin. The fan still works, but you lose speed control and it runs louder than necessary.
Is a 4-pin connector the same as a 4-wire connector?
Not exactly. A 4-pin connector has four contact positions in its housing, but not every position must contain a wire. Some connectors ship with empty cavities. A 4-wire connector specifically has all four contacts populated with conductors, meaning all four circuits are active.
What happens if I plug a 4-pin ATX CPU cable into a 4-pin fan header?
Physically, it won’t fit — the ATX CPU connector uses a 4.2mm pitch while the fan header uses 2.54mm. Forcing it bends pins and damages the socket. Always match the pitch before attempting connection.
Can a 4-pin connector carry both power and data at the same time?
Yes. The M12 D-coded 4-pin connector carries 100BASE-TX Ethernet, which delivers both power (PoE) and data over the same four wires. The JST XH also commonly carries power and a signal line on separate pins within the same housing.
Is a 4-pin DIN connector safe for 110V?
Some 4-pin circular connectors found in 3D printers and industrial equipment are rated for 110V, but a standard DIN 41524 connector is not. Check the manufacturer’s voltage rating on the housing or datasheet before use — assuming it’s low-voltage is a shock hazard.
References & Sources
- Cable Harness Assembly. “4-Pin Connector Types: Complete Selection Guide.” Industry reference on pitch, locking, and electrical specs by connector family.
- SCONDAR. “JST 4 Pin Connector Types.” Detailed breakdown of JST XH, PH, SH, and SM pinouts and current ratings.
- Renhotec Pro. “4 Pin vs 5 Pin DIN Connector: What’s the Difference?” Explains DIN keying, pin assignments, and the MIDI confusion.
- Phidgets. “4-Pin Circular Cable Connector (Male).” IP68-rated waterproof connector specs and applications.
- TE Connectivity. “Types of Electrical Connectors.” Manufacturer overview of M12, M8, and industrial connector standards.
