Blog · Deep dive

i2c cable length: how far can it actually go?

Deep dive

i2c was designed to cross a circuit board, not a room. But the limit isn't a number of metres — it's 400 picofarads, and once you understand that budget you can spend it deliberately.

The physics

i2c cable length is really about capacitance

Because the bus is open-drain, every rising edge is just a resistor charging the capacitance of the wiring — an RC curve, not a clean digital edge. The spec gives Standard- and Fast-mode a total budget of 400 pF; beyond it, edges get too lazy to arrive inside the timing windows and bits start smearing into each other. Falling edges stay sharp (a transistor yanks the line down), which is why a failing long bus corrupts data in one direction of the waveform first — instantly recognisable on a logic analyzer.

Everything on the bus spends the budget: each device pin (~10 pF), each connector, and above all the cable — ordinary hookup wire or ribbon runs 50–100 pF per metre. Do the arithmetic and the honest numbers appear: a couple of metres at 100 kHz, half that at 400 kHz, minus whatever your connector chain already ate.

Free fixes first

Stretching the 400 pF budget: free fixes first

Slow the clock. The cheapest metre-multiplier there is. At 10 kHz the bit windows are 10× wider than Standard-mode, so the same lazy edges pass with room to spare. Sensor data doesn't care — a temperature reading at 10 kHz still takes under 10 ms.

Strengthen the pull-ups. A stiffer resistor charges the cable faster. Go as low as the 1 kΩ floor allows, remembering that chained breakouts already parallel their onboard resistors toward that floor on their own.

Route the wires right. Never twist or ribbon SDA directly against SCL — clock edges couple into the data line. In a multi-core cable, give each signal a ground partner: SDA+GND twisted, SCL+GND twisted, the two pairs kept apart. That layout alone rescues many borderline runs.

Drop 5 V logic on the wire if you can't shield. A higher swing buys noise margin: some builders run the cable at 5 V and level-shift at the 3.3 V ends. (Check both ends' tolerance in the compatibility checker before trying this.)

Active hardware

i2c bus extenders: when wire tricks run out

Bus buffers (P82B715, PCA9600, PCA9517). These sit at each end and drive the long middle section at ~10× lower impedance, effectively multiplying the capacitance budget. With low-capacitance cable, runs of 20–50 m become realistic while both ends still look like ordinary i2c. The PCA9517 adds voltage-level translation on top of buffering — useful if the two ends of the run sit at different logic voltages, not just different capacitance.

Differential extenders (PCA9615). The serious answer. Each line becomes a balanced pair over Cat5 — the same trick RS-485 uses — shrugging off the noise that murders single-ended i2c. Off-the-shelf boards (SparkFun's QwiicBus line) bolt this straight onto a Qwiic chain and happily cover tens of metres between rooms.

Or move the problem. Past a certain distance the winning move is architectural: a small microcontroller at the sensor, speaking i2c across centimetres, then shipping results back over RS-485, CAN or radio. Every metre i2c doesn't travel is a metre it can't fail on.

Rules of thumb

i2c cable length cheat sheet

Inside an enclosure: do nothing, it just works. One to two metres: 100 kHz, 2.2 kΩ pull-ups, sane wire routing. Two to ten metres: 10 kHz and strong pull-ups, or a P82B715 pair. Beyond ten metres, between rooms, or anywhere electrically noisy: differential extender or a remote microcontroller. And whatever the distance — if the bus misbehaves, the troubleshooting checklist separates a length problem from a wiring one in minutes.

Questions

Cable length FAQ

What is the maximum cable length for i2c?

There is no distance in the spec — the limit is 400 pF of total bus capacitance. Ordinary cable adds roughly 50–100 pF per metre, so in practice: a metre or two is comfortable at 100 kHz, half that at 400 kHz, and multi-metre runs need a slower clock or an active extender.

Does lowering the clock speed really let me go further?

Yes — it's the single most effective free fix. The capacitance is still there, but at 10 kHz the timing windows are ten times wider, so the slow rising edges still arrive in time. Many 'impossible' 5–10 m runs work fine at 10 kHz with strong pull-ups.

Can I run i2c over Cat5/Ethernet cable?

Plain Cat5 carrying raw SDA/SCL works only for short runs — its pairs add capacitance quickly, and never twist SDA with SCL (crosstalk). The right way is a differential extender like the PCA9615, which converts each line to a balanced pair over Cat5 and comfortably reaches tens of metres.

How far can Qwiic / STEMMA QT chains go?

Off-the-shelf cables run 50–500 mm, and that's deliberate — the ecosystem is designed for inside-the-enclosure distances. A long daisy-chain also stacks connector contacts and per-board pull-ups, so the practical ceiling is about a metre of total chain before things get marginal.

When should I give up on extending i2c?

When the run is longer than a room or leaves the building's electrical environment (outdoor sensors, motors nearby). Put a small microcontroller next to the sensor and send the readings back over something built for distance — RS-485, CAN, or radio. A $2 MCU beats an afternoon of bus debugging.