Raspberry Pi Pico 2 pinout
The second-generation Pico with the faster RP2350 chip, twice the memory and 4 MB flash. Same 40-pin layout as the Pico, 3.3 V logic.
The real app with a simulated Raspberry Pi Pico 2, running in your browser. No install, nothing to plug in.
At a glance
- Chip
- RP2350 (RP2350A)
- Processor
- Dual-core Arm Cortex-M33 or RISC-V Hazard3 at 150 MHz, 520 KB SRAM, 4 MB flash
- Logic level
- 3.3 V. Not 5 V tolerant unless marked below.
- Flashing tool
- picotool (UF2)
- Arduino board (FQBN)
- rp2040:rp2040:rpipico2
- Live pin view in BoardPilot
- Yes (diagnostic agent available)
Pins to avoid or use with care
Debug port: SWCLK, SWDIO
SWD/JTAG. Using them can stop a debugger from reaching the chip.
Good pins for LEDs, buttons and signals
GP15, GP14, GP13, GP12, GP11, GP10, GP22, GP21, GP20, GP6, GP7, GP2, GP3
Default pins in Arduino
- I2C
- SDA = GP4, SCL = GP5. Only these pins work with the Wire library defaults. Only certain pin pairs can be I2C on this chip, and SDA and SCL cannot be swapped in software. Wire uses GP4 (SDA) and GP5 (SCL); Wire.setSDA()/Wire.setSCL() before Wire.begin() can move I2C0 to GP0/GP1, GP8/GP9, GP12/GP13, GP16/GP17 or GP20/GP21. Wire1 defaults to GP26/GP27.
- SPI
- MOSI = GP19, MISO = GP16, SCK = GP18, CS = GP17.
- Analog inputs
- GP26, GP27, GP28 (0–3.3 V)
- 5 V tolerant pins
- GP0, GP1, GP2, GP3, GP4, GP5, GP6, GP7, GP8, GP9, GP10, GP11, GP12, GP13, GP14, GP15, GP16, GP17, GP18, GP19, GP20, GP21, GP22
How to flash it
If the board is not found, hold the BOOTSEL button while plugging in the USB cable.
All 43 pins
| Pin | GPIO | Chip pin | Functions | Notes |
|---|---|---|---|---|
| GP0 | 0 | GPIO, UART0_TX, SPI0_MISO, I2C0_SDA, PWM0_A, Serial1_TX | Tolerates 5 V inputs, but only while the board is powered. | |
| GP1 | 1 | GPIO, UART0_RX, SPI0_CS, I2C0_SCL, PWM0_B, Serial1_RX | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP2 | 2 | GPIO, UART0_CTS, SPI0_SCK, I2C1_SDA, PWM1_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP3 | 3 | GPIO, UART0_RTS, SPI0_MOSI, I2C1_SCL, PWM1_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GP4 | 4 | GPIO, I2C_SDA (default), UART1_TX, SPI0_MISO, I2C0_SDA, PWM2_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP5 | 5 | GPIO, I2C_SCL (default), UART1_RX, SPI0_CS, I2C0_SCL, PWM2_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP6 | 6 | GPIO, UART1_CTS, SPI0_SCK, I2C1_SDA, PWM3_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP7 | 7 | GPIO, UART1_RTS, SPI0_MOSI, I2C1_SCL, PWM3_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GP8 | 8 | GPIO, UART1_TX, SPI1_MISO, I2C0_SDA, PWM4_A, Serial2_TX | Tolerates 5 V inputs, but only while the board is powered. | |
| GP9 | 9 | GPIO, UART1_RX, SPI1_CS, I2C0_SCL, PWM4_B, Serial2_RX | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP10 | 10 | GPIO, UART1_CTS, SPI1_SCK, I2C1_SDA, PWM5_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP11 | 11 | GPIO, UART1_RTS, SPI1_MOSI, I2C1_SCL, PWM5_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GP12 | 12 | GPIO, UART0_TX, SPI1_MISO, I2C0_SDA, PWM6_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP13 | 13 | GPIO, UART0_RX, SPI1_CS, I2C0_SCL, PWM6_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP14 | 14 | GPIO, UART0_CTS, SPI1_SCK, I2C1_SDA, PWM7_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP15 | 15 | GPIO, UART0_RTS, SPI1_MOSI, I2C1_SCL, PWM7_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GP16 | 16 | GPIO, SPI_MISO (default), UART0_TX, SPI0_MISO, I2C0_SDA, PWM0_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP17 | 17 | GPIO, SPI_CS (default), UART0_RX, SPI0_CS, I2C0_SCL, PWM0_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP18 | 18 | GPIO, SPI_SCK (default), UART0_CTS, SPI0_SCK, I2C1_SDA, PWM1_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP19 | 19 | GPIO, SPI_MOSI (default), UART0_RTS, SPI0_MOSI, I2C1_SCL, PWM1_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GP20 | 20 | GPIO, UART1_TX, SPI0_MISO, I2C0_SDA, PWM2_A | Tolerates 5 V inputs, but only while the board is powered. | |
| GP21 | 21 | GPIO, UART1_RX, SPI0_CS, I2C0_SCL, PWM2_B | Tolerates 5 V inputs, but only while the board is powered. | |
| GND | — | GND | ||
| GP22 | 22 | GPIO, UART1_CTS, SPI0_SCK, I2C1_SDA, PWM3_A | Tolerates 5 V inputs, but only while the board is powered. | |
| RUN | — | RESET | Reset pin. Connect it to GND for a moment to restart the board. It has an internal pull-up. | |
| GP26 | 26 | GPIO, ADC0, UART1_CTS, SPI1_SCK, I2C1_SDA, PWM5_A, Wire1_SDA | Analog input ADC0 (0 to 3.3 V). Never put more than 3.3 V on this pin. | |
| GP27 | 27 | GPIO, ADC1, UART1_RTS, SPI1_MOSI, I2C1_SCL, PWM5_B, Wire1_SCL | Analog input ADC1 (0 to 3.3 V). Never put more than 3.3 V on this pin. | |
| AGND | — | GND, ADC_GND | Analog ground for GP26 to GP28. Use it as the ground for analog sensors. | |
| GP28 | 28 | GPIO, ADC2, UART0_TX, SPI1_MISO, I2C0_SDA, PWM6_A | Analog input ADC2 (0 to 3.3 V). Never put more than 3.3 V on this pin. | |
| ADC_VREF | — | ADC_VREF | Reference voltage for the analog inputs (filtered 3.3 V). Do not power parts from it. | |
| 3V3(OUT) | — | 3V3_OUT | 3.3 V output for sensors and modules. Keep the load under 300 mA. | |
| 3V3_EN | — | 3V3_EN | Turns the 3.3 V supply on or off. Leave it unconnected; connecting it to GND switches the board off. | |
| GND | — | GND | ||
| VSYS | — | VSYS | Main power input (1.8 to 5.5 V). From USB it is about 4.7 V (5 V minus a diode drop). | |
| VBUS | — | VBUS | 5 V straight from the USB cable. It is 0 V when USB is not plugged in. | |
| SWCLK | — | SWD_CLK | Debug clock for a debug probe (SWD). Not a GPIO. | |
| GND | — | GND | Ground pin of the 3-pin debug header. | |
| SWDIO | — | SWD_IO | Debug data for a debug probe (SWD). Not a GPIO. |
Questions
Which pins are I2C on the Raspberry Pi Pico 2?
SDA is GP4 and SCL is GP5 (the defaults of the Arduino Wire library). Only certain pins support I2C in hardware, so use these unless you know your core allows others.
Which Raspberry Pi Pico 2 pins should I avoid?
SWCLK, SWDIO (debug port).
Is the Raspberry Pi Pico 2 5 V tolerant?
The chip runs at 3.3 V, but these pins tolerate 5 V inputs: GP0, GP1, GP2, GP3, GP4, GP5, GP6, GP7, GP8, GP9, GP10, GP11, GP12, GP13, GP14, GP15, GP16, GP17, GP18, GP19, GP20, GP21, GP22. The others take at most 3.3 V.
Which pins can read analog voltage on the Raspberry Pi Pico 2?
GP26, GP27, GP28, from 0 to 3.3 V.
How do I upload code to the Raspberry Pi Pico 2?
In the Arduino IDE pick the board rp2040:rp2040:rpipico2 (core rp2040:rp2040). If the board is not found, hold the BOOTSEL button while plugging in the USB cable.
Wiring guides for the Raspberry Pi Pico 2
Step-by-step wiring, voltage checks and test code for the most used parts:
BME280 BMP280 DHT22 DHT11 HC-SR04 SSD1306 OLED MPU6050 DS18B20 WS2812B LED strip SG90 servo Relay module HC-SR501 PIR LCD 1602 I2C INA219 VL53L0X BH1750 MAX30102 RC522 RFID NEO-6M GPS Capacitive soil moisture sensor ADS1115 TM1637 28BYJ-48 stepper L298N Potentiometer Push button LED Joystick module SD card module AHT20
Compare
Raspberry Pi Pico vs Raspberry Pi Pico 2 Teensy 4.1 vs Raspberry Pi Pico 2
Learn the basics
Lesson: What is a microcontroller? Lesson: Hardware basics for software developers Lesson: GPIO: pins in and out Pinout GPIO Logic level (HIGH and LOW) UF2 Bootloader
Check your wiring with BoardPilot
BoardPilot shows this board in 3D, flags risky pins as you wire, and flashes it safely with a backup first.
Download BoardPilotSources
- Raspberry Pi Pico 2 datasheet, 3. Mechanical specification, Figure 3 (51 x 21 x 1 mm, same header grid as Pico)
- Raspberry Pi Pico 2 datasheet, 1. About, Figure 2 pinout; 3.1 Pinout (GPIO23-25, 29 internal); 5.2/5.3 GPIO and ADC
- RP2350 datasheet, 14.8.2 Pin definitions, Table 1427 (GPIO0-25 'Digital IO (FT)': up to 5.5 V while IOVDD is powered; GPIO26-29 ADC pins are not)
- RP2350 datasheet, Errata RP2350-E9: on A2 stepping chips an input pin with the internal pull-down can stay at about 2.2 V; use an external pull-down of 8.2 kOhm or less. Fixed in stepping A3/A4.
- RP2350 datasheet, 9.4 Function select (UART/SPI/I2C/PWM per GPIO)
- earlephilhower/arduino-pico, variants/rpipico2/pins_arduino.h (Wire, SPI, Serial1/2 pins) and boards.txt (board ids, USB ids)
- Raspberry Pi USB product ID list (raspberrypi/usb-pid), Internal PIDs 0x0003, 0x0005, 0x0009, 0x000A, 0x000F
- Board data file and source notes on GitHub