Almost every industrial sensor, including Datalogic photoelectric, contrast and inductive sensors, has a transistor output that is either PNP or NPN. Ordering the wrong one is one of the most common mistakes when replacing a sensor. This guide explains the difference in simple terms.
The difference in one sentence
A PNP (sourcing) output switches the positive supply (+24 V) to the load when the sensor detects an object. An NPN (sinking) output switches the negative (0 V) side to the load.
| PNP (sourcing) | NPN (sinking) | |
|---|---|---|
| Output when active | +V (e.g. 24 V) | 0 V |
| Load connected between | Output and 0 V | Output and +V |
| Matching PLC input | Sinking input (common to 0 V) | Sourcing input (common to +V) |
| Common in | India, Europe, most new machines | Japanese and some Asian machines, older equipment |
Standard wire colours (3- and 4-wire DC sensors)
- Brown: +V supply (10–30 Vdc)
- Blue: 0 V
- Black: switching output (usually NO)
- White: second output (NC or complementary) on 4-wire models
The same colours apply to standard M12 and M8 cables (pin 1 brown, pin 3 blue, pin 4 black, pin 2 white). Always check the datasheet, because some models use pin 2 for a teach or test input.
How to tell PNP from NPN in a Datalogic model code
Datalogic codes usually end with letters that describe the output. For example:
- S5N-PA-5-B01-PP: PNP output.
- SM-PR-2-D00-NN: NPN output.
- S62-PA-5-B01-PP: PNP output.
- S3N-PR-2-M01-N vs S3N-PR-2-M01-P: the same sensor in NPN and PNP versions.
Some models offer both, or let you select the output: the TL50-W-815 has one PNP and one NPN output, and the TL46-W-815 lets you choose.
How to choose
- Look at the PLC input card or machine manual: is the input common connected to 0 V (use PNP) or to +24 V (use NPN)?
- If you are replacing a sensor, copy the old one: read the full model code on its label.
- For new machines in India, PNP is the usual standard.
Frequently asked questions
Can I use a PNP sensor on an NPN PLC input?
Not directly. The input will not see the signal. You need either the correct sensor type or an interface relay.
Which is better, PNP or NPN?
Neither is better; they must match the input. PNP is more common in India and Europe, NPN on many Japanese machines.
What do NO and NC mean?
Normally open (NO) means the output switches on when the object is detected. Normally closed (NC) means it switches off. Many Datalogic sensors offer both or a light/dark setting.
My old sensor label is unreadable. What can I do?
Send us a photo of the sensor and the wiring, and tell us the PLC input type. We will suggest the right Datalogic replacement.
Related: Datalogic photoelectric sensors: complete guide and inductive proximity sensors guide.
Buy from VXT Sensor
VXT Sensor, Noida, supplies genuine Datalogic (Datasensing) sensors across India. Send us the model code or describe your application, and we will confirm the right model, datasheet, price and delivery time. Send an enquiry or call +91 99530 39482.



