USB Wiring Diagram

Usb Wiring Diagram — circuit diagram showing component connectionsUSBUSB-A PlugUSBUSB-A ReceptacleCable VBUSCable GNDUSB Cable PinoutVBUS = 5V, D+/D- data, GND
USB Wiring Diagram — interactive diagram. Open it in the editor to customise components and wiring.

This is a free printable usb wiring diagram: download the diagram as SVG or open it and print to paper or PDF.

A USB wiring diagram shows the colour-coded pin assignments for USB cables: VBUS (red, 5 V), D− (white), D+ (green), and ground (black) for USB 2.0, with USB-C introducing additional pins for orientation and high-speed protocols.

USB (Universal Serial Bus) is a standardised connection architecture for data transfer and power delivery between devices. Understanding the wiring diagram is essential for cable repair, custom adapter construction, embedded systems integration, and fault diagnosis.

USB 2.0 Type-A and Type-B connectors follow a four-conductor arrangement:

Pin 1 — VBUS (red): The 5 V DC supply rail, sourced from the host (computer, charger, hub). A standard USB 2.0 host port provides up to 500 mA (2.5 W). USB Battery Charging (BC 1.2) allows up to 1.5 A, and USB Power Delivery (PD) via compatible connectors can deliver up to 240 W (USB PD 3.1).

Pin 2 — D− (white): The USB differential data minus conductor. Together with D+, this forms the differential data pair. USB 2.0 full-speed and high-speed data transmission uses a single differential pair for bidirectional half-duplex communication.

Pin 3 — D+ (green): The USB differential data plus conductor.

Pin 4 — GND (black): Ground return, shared by both power and data signals.

The D+ and D− pair transmits data differentially — noise appearing equally on both conductors cancels at the receiver, providing robustness against interference. USB 2.0 high-speed operates at 480 Mbps; full-speed at 12 Mbps; low-speed at 1.5 Mbps.

USB-C is significantly more complex. A USB-C connector has 24 pins including: two VBUS pins, two ground pins, two pairs of SuperSpeed data lanes (TX1+/TX1−/RX1+/RX1−/TX2+/TX2−/RX2+/RX2−), one D+/D− pair (for USB 2.0 compatibility), two Configuration Channel (CC1, CC2) pins for plug orientation detection and USB PD negotiation, a Sideband Use (SBU1, SBU2) pair, and multiple ground/shield connections. The CC pins are the mechanism by which a USB-C cable and charger negotiate the delivery of up to 240 W or protocols such as DisplayPort, Thunderbolt, and USB4.

Active USB-C cables contain electronics (E-marker chips) that identify cable capabilities. A passive USB-C cable advertises its specifications via resistors on the CC pins. These details are invisible in the physical wiring but critical to correct operation.

How to wire usb wiring diagram

  1. Identify the USB connector types at each end of the cable Determine what connector types you are working with: Type-A (flat rectangular, host end), Type-B (square with chamfered corners, device end), Mini-B, Micro-B, or USB-C. The connector type determines the number of pins and their physical arrangement. For USB 2.0 Type-A and Type-B, there are four pins. Micro-B adds a fifth pin (ID pin) used in USB OTG (On-The-Go) applications.
  2. Identify the four conductors by colour Open or prepare the cable and identify the four conductors. Standard colours are: red (VBUS, pin 1), white (D−, pin 2), green (D+, pin 3), black (GND, pin 4). In some aftermarket or non-standard cables the colours may vary — verify with a multimeter against a known connector or wiring diagram if in doubt.
  3. Prepare the conductors Strip the cable's outer jacket. The D+ and D− conductors are typically individually shielded with foil within the cable — maintain this shielding as long as possible to preserve data integrity. Strip only enough insulation for the connection being made (for soldering into a connector, approximately 2–3 mm of conductor insulation).
  4. Connect VBUS (pin 1, red) to the connector Solder or crimp the red VBUS conductor to pin 1 of the USB connector. In USB Type-A male connectors, pin 1 is the leftmost pin when looking at the connector face with the contacts facing towards you and the key (wider flat side) at the bottom.
  5. Connect D− (pin 2, white) and D+ (pin 3, green) Connect the white conductor to pin 2 (D−) and the green conductor to pin 3 (D+). Keep the data pair conductors as short as possible between the cable end and the connector pins. Do not cross D+ and D− — crossing the differential pair will prevent data communication entirely (though power will still flow).
  6. Connect GND (pin 4, black) and cable shield Connect the black GND conductor to pin 4. The cable's outer shield (braid or foil) should connect to the connector's metal shell/housing, which provides EMI shielding for the cable assembly. Do not confuse the shield with the GND conductor — in USB cables these are separate conductors serving different functions.
  7. Test the connection For a power-only connection, verify VBUS and GND continuity and correct polarity. For a data connection, test by connecting a device and host: if the device is recognised and data transfers correctly, the D+ and D− are correctly wired. A USB protocol analyser can confirm signal quality if data integrity issues are suspected.

Specifications

Pin 1 — VBUSRed; 5 V DC nominal; 4.75–5.25 V at full USB 2.0 load
Pin 2 — D−White; differential data minus
Pin 3 — D+Green; differential data plus
Pin 4 — GNDBlack; ground return
USB 2.0 max cable length (high-speed)5 metres
USB 2.0 host port current (standard)500 mA at 5 V (2.5 W)
USB BC 1.2 max charging current1.5 A at 5 V
USB PD 3.1 maximum power240 W (48 V / 5 A)
USB-C additional pinsCC1, CC2 (orientation/PD negotiation); SBU1, SBU2; SuperSpeed TX/RX pairs; multiple VBUS and GND

Safety warnings

Tools needed

Common mistakes

Troubleshooting

Device receives power from USB cable but is not recognised by host
Cause: D+ and D− conductors are crossed, disconnected, or the cable is a charge-only type with no data conductors Fix: Test with a known-good data cable. Use a USB cable tester to verify all four pins. If using a custom cable, check that green is on pin 3 (D+) and white is on pin 2 (D−) and neither is open-circuit.
USB device disconnects intermittently, especially when the cable is moved
Cause: Damaged conductor inside the cable from flexing, or a cold solder joint at a custom connector Fix: Flex the cable near each end while monitoring the connection. Identify the fault location. If in a custom assembly, resolder the connector. If in a factory cable, replace it — internal cable conductor repairs are not reliable.
USB power delivery fails to negotiate above 5 V
Cause: Missing or damaged CC wire in USB-C cable, or cable is not E-marked for the required PD power level Fix: Verify the USB-C cable is rated for USB PD at the required wattage. An E-marker chip tester can verify cable capabilities. If a basic USB-C cable is used, it will only negotiate 5 V/0.9 A regardless of charger capability.
Excessive voltage drop on VBUS causing device instability or slow charging
Cause: Undersized VBUS conductor for the load current, or excessive cable length Fix: Measure VBUS voltage at the device end of the cable under load with a multimeter. More than 0.25 V drop from the host port indicates undersized wiring or excessive cable length. Use a shorter, higher-quality cable with 24 AWG (or larger) power conductors.

Frequently asked questions

What are the standard USB 2.0 wire colours?

USB 2.0 uses four wires with a widely followed colour convention: red (VBUS, 5 V power), white (D−, data minus), green (D+, data plus), and black (GND, ground). This colour coding is specified in the USB 2.0 specification's cable and connector requirements and is consistent across the vast majority of commercially produced USB 2.0 cables.

Why does USB-C require CC pins that older USB connectors did not?

USB-C connectors are symmetric (no orientation), so the CC1 and CC2 pins are needed to detect which way the plug is inserted and configure the data lanes accordingly. CC pins also carry USB Power Delivery communication, allowing the charger and device to negotiate voltage and current levels above the standard 5 V/0.9 A. Without CC negotiation, a USB-C port defaults to 5 V/0.9 A.

Can I use a USB 2.0 cable for USB 3.0 data transfer?

No. USB 3.0 (and higher) requires the additional SuperSpeed conductor pairs that are present in USB 3.x cables and connectors. A USB 2.0 cable connected to USB 3.0 ports will limit data transfer to USB 2.0 high-speed (480 Mbps) because the SuperSpeed pairs are absent. Power delivery will function normally via VBUS and GND.

Is it safe to cut and splice a USB cable for an extension?

Only for very short extensions at low speeds and with proper splicing. The USB specification limits cable length for data integrity reasons: 5 metres for USB 2.0 high-speed, 3 metres for USB 3.0. Splicing introduces resistance and capacitance that can degrade signal quality. For power-only applications (charging), longer extensions are generally acceptable if wire gauge is adequate to avoid excessive voltage drop.

What is the D+ tie to 3.3 V or resistor method for USB charging detection?

Some USB chargers and power-only hubs indicate charge capability to connected devices by tying D+ and D− to specific voltage levels or resistor divider values. The USB Battery Charging specification (BC 1.2) defines the DCP (Dedicated Charging Port) method: D+ and D− are shorted together at the charger, signalling to the device that up to 1.5 A is available. Proprietary fast-charge protocols use different voltage levels on D+ and D−.

Related diagrams

Free electrical calculators

Edit this diagram free in the online editor