4DVolt

Arduino Uno: complete pinout

The Arduino Uno R3 has 14 digital pins, 6 analog inputs and several pins with special functions. See the complete pinout, which pins do PWM, I2C, SPI and UART, the electrical limits, and filter the map by function.

Arduino Uno R3 board
Arduino Uno R3

Specifications

Microcontroller
ATmega328P, 8-bit, 16 MHz
Operating voltage
5 V
Recommended input (Vin)
7 V to 12 V (limits 6 V to 20 V)
Digital pins
14 (D0 to D13), 6 with PWM
Analog inputs
6 (A0 to A5), 10-bit ADC
Current per pin
20 mA recommended (max 40 mA)
Memory
32 KB flash, 2 KB RAM, 1 KB EEPROM
3.3 V current
up to 50 mA

Pinout

Digital pins D0 to D13 are along the top of the board and analog pins A0 to A5 along the bottom, next to the power pins. The analog pins also work as digital (D14 to D19).

Power

5V 5V Regulated 5 V output (or input, if powering through it)
3V3 3V3 3.3 V output, up to 50 mA
GND GND Ground (three pins)
VIN VIN External supply input, 7 V to 12 V
AREF AREF ADC reference voltage
RESET RESET Resets the board when pulled LOW

Special functions

D0 RX Serial (UART), shared with USB
D1 TX Serial (UART), shared with USB
D2 INT0 External interrupt 0
D3 INT1 External interrupt 1 (also PWM)
D10 SS SPI: slave select (also PWM)
D11 MOSI SPI: master data out (also PWM)
D12 MISO SPI: slave data out
D13 SCK SPI: clock; board LED
A4 SDA I2C: data
A5 SCL I2C: clock

Arduino Uno pin map

Pick a function to see which pins provide it.

Pins A0 to A5 also work as digital (D14 to D19). Highlighted pins provide the selected function.

How to wire it

Power: through the USB cable (5 V from the computer) or through the barrel jack / VIN pin with 7 V to 12 V. The board has a regulator and supplies 5 V and 3.3 V to modules.

Each digital input or output pin handles 20 mA comfortably, and the sum of all pins should not exceed ≈ 200 mA. For motors, relays and LED strips use a transistor or driver.

The analog inputs read 0 V to 5 V (or up to the AREF voltage) in 1024 steps. Each step is ≈ 4.9 mV.

Pins 0 and 1 are shared with USB: if you connect something to them, code upload may fail. Prefer pins 2 to 13 for your modules.

I2C: SDA is A4 and SCL is A5 (they also appear next to AREF). SPI: SS is D10, MOSI D11, MISO D12 and SCK D13. External interrupts only on pins 2 and 3.

Example code (Arduino)

Sketch that fades an external LED on pin 9 (PWM).

#define LED_PIN 9   // PWM pin (~)

void setup() {
  pinMode(LED_PIN, OUTPUT);
}

void loop() {
  for (int b = 0; b <= 255; b += 5) {
    analogWrite(LED_PIN, b);
    delay(20);
  }
  for (int b = 255; b >= 0; b -= 5) {
    analogWrite(LED_PIN, b);
    delay(20);
  }
}

Common mistakes

  • Using analogWrite on a pin without PWM: the pin only goes to 0 V or 5 V. Check for the tilde (~) on the silkscreen.
  • Connecting something to pins 0 and 1 and wondering why upload fails or Serial.print stops working.
  • Pulling more than 40 mA from a pin, such as driving a motor or several LEDs directly: the pin burns out. Use a transistor.
  • Feeding more than 12 V into VIN: the regulator overheats and shuts the board down.
  • Connecting a 3.3 V device output straight to a 5 V input: convert the logic level.

Always check the manufacturer's datasheet for your exact model: pin order can vary between modules.

Frequently asked questions

Which Arduino Uno pins have PWM?

Pins 3, 5, 6, 9, 10 and 11, marked with a tilde (~) on the board.

What are the Arduino Uno I2C pins?

SDA is A4 and SCL is A5. They also appear on two extra pins near AREF.

How many analog pins does the Arduino Uno have?

Six, A0 to A5, with a 10-bit ADC (0 to 1023). They also work as digital pins 14 to 19.

What is the maximum current of an Arduino Uno pin?

The absolute limit is 40 mA per pin, but use 20 mA at most. The sum of all pins should not exceed about 200 mA.

Other components