This guide covers the full 40-pin layout, the power pins, and the part that trips up most people coming from a full-size Pi: how I2C, SPI, and UART actually get assigned to pins on the Pico. If you're comparing boards before committing to one, our Raspberry Pi Pico vs. Arduino comparison covers the broader hardware and ecosystem differences — and if you landed here from a Pi 4 or Pi 5 project, see our Raspberry Pi GPIO Pinout overview for how the boards compare.
The Basics: 40 Pins, 26 GPIOs
The Pico has 40 pins total, arranged 20 per side, but only 26 of them are usable general-purpose GPIOs — labeled GP0 through GP22, then GP26 through GP28. Four GPIO numbers in that range are deliberately skipped on the header: GP23, GP24, GP25, and GP29 aren't exposed as physical pins at all. They're wired internally instead:
| Internal GPIO | Function |
|---|---|
| GP23 | Controls the onboard power supply's power-save mode |
| GP24 | Senses whether USB (VBUS) power is present |
| GP25 | Drives the onboard LED |
| GP29 | Used internally to monitor the VSYS voltage in ADC mode |
If you ever see a tutorial reference GP23 or GP25 as if you can wire something to it, that's a mistake — these four are fixed to internal board functions and don't appear on the header.
Power Pins: 3V3(OUT), VSYS, and VBUS
This is the biggest naming trap for anyone coming from a Pi 4 or Pi 5. There's no "5V pin" and "3.3V pin" pair in the way you'd expect — instead, the Pico has three distinctly named power pins, each with a different role:
| Pin | Role | Notes |
|---|---|---|
| 3V3(OUT) | Regulated 3.3V output | Generated on-board by the Pico's own switching regulator — safe to use for powering small external sensors and modules |
| VSYS | Main system voltage input | Accepts 1.8V–5.5V; this is where you'd feed external power if not powering via USB (a Schottky diode is recommended for external supplies, per the RP2040 datasheet) |
| VBUS | USB power input | Carries whatever voltage is present on the Micro USB port — typically 5V when powered via USB |
The GPIO pins themselves still run at the same 3.3V logic level as every other Raspberry Pi board — and are not 5V tolerant. Feeding 5V into a GPIO pin (as opposed to VSYS or VBUS, which are designed for it) can damage the RP2040.
Full Pin Layout
The Pico's 40 pins are split 20 per side. Ground pins are spread across both sides (8 total), and the remaining pins are the 26 GPIOs plus the three power pins and three debug pins.
| Pin category | Count | Details |
|---|---|---|
| GPIO (general purpose) | 26 | GP0–GP22, GP26–GP28 |
| Ground (GND) | 8 | Spread across both sides of the header |
| Power | 3 | 3V3(OUT), VSYS, VBUS |
| Debug (SWD) | 3 | SWDIO, GND, SWCLK — located at the bottom edge of the board, separate from the main header |
How I2C, SPI, and UART Actually Work on the Pico
Here's the part that catches people off guard coming from a Pi 4 or Pi 5: on those boards, I2C is fixed to GPIO2/GPIO3, SPI is fixed to a specific set of pins, and so on. On the Pico, it doesn't work that way. Every communication peripheral — I2C, SPI, and UART — can be mapped to several different GPIO pins, not just one fixed location.
The RP2040 has two instances of each peripheral (I2C0 and I2C1, SPI0 and SPI1, UART0 and UART1), and each instance is available on more than one possible pin pair. The table below shows the most commonly used default pins for each — but if a project or library asks you to use different pins, that's usually still valid, as long as both pins belong to the same peripheral instance.
| Peripheral | Common default pins | Notes |
|---|---|---|
| I2C0 | GP4 (SDA), GP5 (SCL) | Also available on GP0/GP1 and other pin pairs |
| I2C1 | GP2 (SDA), GP3 (SCL) | Also available on GP6/GP7 and other pin pairs |
| SPI0 | GP16 (MISO), GP17 (CS), GP18 (SCK), GP19 (MOSI) | Also mappable to other pin groups on the same instance |
| SPI1 | GP10 (SCK), GP11 (MOSI), GP12 (MISO) | Also mappable to other pin groups on the same instance |
| UART0 | GP0 (TX), GP1 (RX) | Three possible pin pairs total for UART0 |
| UART1 | GP8 (TX), GP9 (RX) | Two possible pin pairs total for UART1 |
The one hard rule: you can't mix pins from two different instances of the same peripheral. For example, you can run I2C0 on one pair of pins and I2C1 on a separate pair simultaneously, but you can't use two separate GPIO pairs for I2C0 at the same time. Always check the specific pin assignment your library or project expects rather than assuming a "default."
ADC and PWM Pins
The Pico has onboard analog-to-digital conversion, something the full-size Pi models don't expose on their GPIO header at all:
- 3 external ADC channels on GP26, GP27, and GP28 — each readable as either a digital GPIO or an analog input, switchable in software.
- 1 internal ADC channel connected to the onboard temperature sensor (not exposed as a physical pin).
For PWM, nearly every GPIO pin can generate a PWM signal. The RP2040 has 8 PWM "slices," each providing 2 channels (A and B) — 16 channels in total. Because there are more GPIO pins than PWM channels, some pins share the same channel (for example, GP0 and GP16 both map to the same PWM channel), so if you need two independent PWM signals, check that they don't land on the same slice.
FAQ
How many usable GPIO pins does the Raspberry Pi Pico have?
26 out of its 40 total pins are usable GPIOs, labeled GP0 through GP22 and GP26 through GP28. Four GPIO numbers in that range (GP23, GP24, GP25, GP29) are reserved for internal board functions and aren't exposed on the header.
What's the difference between 3V3(OUT), VSYS, and VBUS on the Pico?
3V3(OUT) is a regulated 3.3V output you can use to power small external components. VSYS is the main system voltage input, accepting 1.8V to 5.5V if you're powering the board without USB. VBUS carries whatever voltage is present on the USB port, typically 5V.
Is the Raspberry Pi Pico's I2C pin fixed like on a Raspberry Pi 4?
No. Unlike the Pi 4 and Pi 5, where I2C is fixed to specific pins, the Pico's I2C (and SPI and UART) can be mapped to several different GPIO pin pairs. GP4/GP5 is a common default for I2C0, but other pin pairs work as well, as long as they belong to the same peripheral instance.
Can I connect a 5V device to the Raspberry Pi Pico's GPIO pins?
Not directly. The Pico's GPIO pins run at 3.3V logic and are not 5V tolerant, the same as every other Raspberry Pi board. Use a level shifter for 5V sensors or devices. The VSYS and VBUS power pins are separate from the GPIO pins and are designed to accept higher voltages.
Prototyping a custom board around the Raspberry Pi Pico?
