Proximity sensors are indispensable components in modern industrial automation, providing non-contact detection of metallic or, in some cases, non-metallic objects. Correct wiring is fundamental to their reliable operation, safety, and longevity. This tutorial provides a comprehensive guide to wiring common types of proximity sensors, adhering to standard industrial practices.
Understanding Sensor Types and Outputs
Before connecting any wires, identify your sensor's type and output configuration. The two primary categories are Inductive (detects metals) and Capacitive (detects various materials including liquids and plastics). Each comes in multiple output types:

DC Sensors (2-wire, 3-wire, 4-wire): The most common in industrial settings. They require a DC power supply, typically 10-30V DC.

2-Wire: Acts like a switch in series with the power supply and load. Polarity is often not critical, but the load must be connected correctly.

3-Wire: The standard configuration. Wires are: Brown (+V DC), Blue (0V DC / Common), and Black (Switched Output). Provides NPN (sinking) or PNP (sourcing) outputs.
4-Wire: Contains two separate outputs (e.g., one NPN and one PNP, or a Normally Open and Normally Closed pair).
AC Sensors (2-wire): Designed for direct connection to AC mains (e.g., 90-250V AC). Function similarly to a 2-wire DC sensor but for AC circuits.
Crucial Pre-Wiring Steps
1. Consult the Datasheet: Always refer to the manufacturer's documentation for the specific wiring diagram, voltage ratings, output current, and connection designations.
2. Power Down: Ensure the control circuit or power supply is completely de-energized and locked out/tagged out (LOTO) before starting.
3. Identify Wires: Standard color coding (IEC 60947-5-2) is common: Brown (+V), Blue (Common/0V), Black (Output), White (Output 2 or auxiliary function).
Detailed Wiring Procedure for a 3-Wire DC Sensor
This covers the majority of installations.
1. Power Supply Connection: Connect your regulated DC power supply's positive terminal (+) to the sensor's Brown wire. Connect the power supply's negative terminal (-) to the sensor's Blue wire. Use ferrules or properly stripped and secured wire ends.
2. Output Load Connection: The Black wire is the switched signal output. Its connection depends on the output type (NPN or PNP).
For a PNP (Sourcing) Sensor: The Black wire outputs positive voltage when activated. Connect the Black wire to your load (e.g., PLC input, relay coil). The other side of the load must then be connected to the power supply's negative (Blue/0V) line.
For an NPN (Sinking) Sensor: The Black wire sinks current to 0V when activated. Connect one side of your load to the positive supply (Brown). Connect the other side of the load to the sensor's Black wire. The sensor internally connects this to 0V when triggered.
3. Shield Connection (if applicable): For sensors in electrically noisy environments, connect the drain wire or shield of the cable to a functional earth (FE) or ground point at the controller end only. Do not connect at both ends to avoid ground loops.
Wiring a 2-Wire DC/AC Sensor
These sensors are wired in series with the load and power supply. For DC types, observe polarity if marked. Connect one sensor wire to one side of the power supply. Connect the other sensor wire to your load. Finally, connect the remaining load terminal to the other side of the power supply, completing the series circuit. Ensure the sensor's leakage current (when "off") is compatible with your load's minimum operating current.
Critical Installation & Testing Tips
Mounting: Ensure the sensor is properly mounted, respecting its sensing distance and avoiding contact with metal mounting surfaces for inductive types.
Wire Management: Use conduit or cable carriers in harsh environments. Keep sensor cables away from high-voltage power lines and motor drives to prevent electromagnetic interference.
Testing: After wiring, power up the system. Use the sensor's indicator LED (if present) to verify detection. Measure the output voltage with a multimeter to confirm it switches correctly between the "on" and "off" states when a target is presented and removed.
Load Compatibility: Verify that the sensor's maximum switching current and voltage meet or exceed your load's requirements