← All parts

SSD1306 0.96" OLED (I2C)

Generic

The common 0.96-inch 128x64 monochrome OLED module driven by the SSD1306 controller over I2C. Four pins; default I2C address 0x3C. No backlight (self-emissive), readable at wide angles.

In stock

Specifications

0

No specs listed.

Pinout

4
PinNameFunctionsNotes
1GND
GND
Ground
2VCC
POWER
3.3-5V supply
3SCL
I2C
I2C clock
4SDA
I2C
I2C data

Interactive pinout

Highlight:
BOARD

Click a pin to copy its name · tap a tag above to spotlight a bus.

Starter code

Community starter examples — minimal, unofficial, and provided to get you wiring fast. Verify against the manufacturer datasheet before relying on them.

Arduino (C++)

Arduino library: Adafruit SSD1306 (+ Adafruit GFX Library)

arduino
// SSD1306 128x64 OLED over I2C — community starter example
#include <Wire.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>

Adafruit_SSD1306 display(128, 64, &Wire, -1);  // -1 = no reset pin

void setup() {
  Serial.begin(115200);
  if (!display.begin(SSD1306_SWITCHCAPVCC, 0x3C)) {   // 0x3C is typical
    Serial.println("SSD1306 not found");
    while (1) delay(10);
  }
  display.clearDisplay();
  display.setTextSize(1);
  display.setTextColor(SSD1306_WHITE);
  display.setCursor(0, 0);
  display.println("Hello, pinouts!");
  display.display();
}

void loop() {}

MicroPython

MicroPython library: ssd1306 (micropython-lib)

python
# SSD1306 128x64 OLED over I2C (ESP32) — community starter example
# lib: ssd1306.py (micropython-lib)
from machine import Pin, I2C
import ssd1306

i2c = I2C(0, scl=Pin(22), sda=Pin(21))
oled = ssd1306.SSD1306_I2C(128, 64, i2c)   # address 0x3C
oled.fill(0)
oled.text("Hello, pinouts!", 0, 0)
oled.show()

Wiring

PinArduino Uno R3ESP32 DevKitC (WROOM-32)Notes
GNDGNDGND
VCC+5V3V3Most modules accept 3.3-5 V
SCLA5/SCLGPIO22
SDAA4/SDAGPIO21

Typical uses

  • Status and sensor-readout displays
  • Small menus / UI on microcontroller projects

Related parts

2