M12 4-Pin Pinout Diagram for Sensor and Industrial Wiring

4-pin circular connector

Standards: IEC 61076-2-101, DIN EN 61076-2-101

What is the M12 4-Pin pinout?

The M12 4-Pin Industrial Connector has 4 pins. Pin 1 is +V (power). Pin 2 is OUT (data). Pin 3 is GND (ground). Pin 4 is IN (data).

The M12 connector is the backbone of industrial automation and Industry 4.0. The 4-pin A-coded variant is the most common configuration, used for DC-powered sensors (proximity, inductive, photoelectric) and actuators. The A-coding refers to the specific keyway that prevents mating with other M12 variants like D-coded (Ethernet) or B-coded (Fieldbus).

Standards: IEC 61076-2-101, DIN EN 61076-2-101

Filter:
Circular Connector Pinout DiagramInteractive circular connector diagram showing 4 pins with signal names and color coding.Pin 1: +V - Power Supply (+24V DC typical) - Brown wire1Pin 2: OUT - Signal Output - White wire2Pin 3: GND - Ground (0V) - Blue wire3Pin 4: IN - Signal Input - Black wire4M12

Pin Assignment Table

M12 4-Pin Industrial Connector pin assignments - 4 pins
PinSignalTypeDescription
1
+V
powerPower Supply (+24V DC typical) - Brown wire
2
OUT
dataSignal Output - White wire
3
GND
groundGround (0V) - Blue wire
4
IN
dataSignal Input - Black wire

Signal Types

Power
Data
Ground

Common Applications

Industrial sensorsActuatorsFieldbus connectionsEthernet switchesProximity sensorsInductive sensorsPhotoelectric sensorsFactory automationConveyor systemsPackaging machinesCNC machinesRoboticsPLC I/O modules

Confirmed the connector for your build?

Move from connector confirmation into BOM, cutlist, and manufacturing handoff without retyping cavity data into side documents.

Use this connector in the release workflow

The M12 4-Pin connector has 4 pins: Pin 1 (+V, 24V), Pin 2 (OUT), Pin 3 (GND), and Pin 4 (IN). Common in Industrial sensors and Actuators.

M12 A-Coded Pinout (4-Pin)

The M12 connector is the backbone of industrial automation and Industry 4.0. The 4-pin A-coded variant is the most common configuration, used for DC-powered sensors (proximity, inductive, photoelectric) and actuators. The A-coding refers to the specific keyway that prevents mating with other M12 variants like D-coded (Ethernet) or B-coded (Fieldbus).

Wiring Tips & Best Practices

M12 connectors come in male (plug) and female (socket) variants with mirrored pin numbering. Always identify if you are viewing the front face (mating side) or rear (solder side). Standard wire colors: Brown = +V (Pin 1), White = Signal Out (Pin 2), Blue = Ground (Pin 3), Black = Signal In (Pin 4). For NPN sensors, the output switches to ground; for PNP sensors, the output switches to +V. Most modern PLCs accept both types.

Common Issues

Mixing up male/female pin orientation causes wiring errors - always verify which end you are viewing. Over-tightening the locking nut can damage the seal (torque to 0.6-0.8 Nm). Using static-rated cables in drag chain applications leads to premature failure. Ensure IP67 rating is maintained by using properly torqued connections and undamaged seals.

Why Use Interactive Diagrams?

  • Accuracy: Hover over pins to see exact signal names and descriptions
  • Clarity: Color-coded by signal type (power, ground, data)
  • Printable: Export clean diagrams for shop floor reference

Related Connector Pinouts

M12 4-Pin Pinout Diagram | Sensor and Industrial Connector Wiring | WireIt