M8 and M12 Sensor Connectors — Pinouts, Codings and Pre-Wired Cable Practice

Wiring reference compiled by cBallast. 3-page PDF; the full content is on this page.
Brand
Telemecanique
Subject
Sensor connectors and cordsets
Document type
Wiring reference
Reference
2026 edition
Issued
2026-10-03
Pages
3
Format
Web page and PDF

The standard pinouts behind M8 and M12 sensor cabling — 3- and 4-pin M8, 4- and 5-pin A-coded M12 — the colour convention (brown/blue/black/white), when to choose angled versus straight and field-wireable versus moulded, and fault-finding sensor circuits with a meter.

The de-facto standard

Industrial sensors standardised on circular connectors: M8 (3- or 4-pin) for miniature devices, M12 A-coded (4- or 5-pin) for everything else. The conventions that make any brand plug into any cordset:

Pin (M12 A-coded)Wire colourFunction (DC 3/4-wire)
1Brown+24 V
3Blue0 V
4BlackSwitching output (NO or main)
2WhiteSecond output (NC/complementary) or input
5Grey/green-yellowDiagnostics or functional earth (5-pin)

M8 3-pin carries pins 1/3/4 with the same colours; M8 4-pin adds the white. A-coding's keyway prevents mating with B/D-coded (fieldbus/Ethernet) circuits that share the thread.

Cordsets and field-wireable plugs

Moulded cordsets are the reliability choice — vibration-sealed, IP67/IP69K per rating. The catalogue carries straight and angled M8/M12 cordsets in standard lengths (e.g. XZCP0666L5 — angled M8 female, 3-pin, 5 m) and the full XZCP family alongside the sensors. Field-wireable connectors (XZCC12FCM40B — M12 female, angled, 4-pin, screw terminals) rescue odd lengths and on-machine repairs: strip per the insert's gauge, land colours per the table, torque the gland, and treat them as serviceable rather than disposable. Choose angled heads where the cable would otherwise bow against guarding (the strain that kills moulded tails), straight where the exit runs along the mount.

Wiring the three classic circuits

Fault-finding at the connector

With a meter at the open cordset end, the whole sensor circuit is diagnosable in a minute: 24 V between brown and blue (supply present); on a PNP sensor, black→blue reads ~24 V with target present, ~0 V without (output alive); a sensor whose indicator follows the target while the PLC never sees it means cordset or input card, not sensor — swap the cordset first. Chronic connector failures trace to three causes: unsupported cable bouncing at the plug (clamp within 100 mm), coolant wicking through a loose coupling nut (torque it; check the O-ring), and pin corrosion from washdown chemistry (use the stainless/food-grade cordset classes where the sensors themselves are the stainless variants — see the inductive guide).

Open / Download PDF

Compiled by cBallast for identification and cross-reference. Part numbers, designations and trademarks belong to their respective manufacturers. Confirm ratings and dimensions against the manufacturer's current documentation and the nameplate of the installed equipment before ordering or installation.