Sensors

AHT20

Popular Chinese I2C temperature and humidity sensor used as a low-cost SHT-series alternative.

China-madeAosongActiveEasy

Best For

Projects needing I2C and Humidity with a commonly available sensors part.

Avoid If

You need production-grade certainty without checking the exact module vendor, pinout, and library maintenance status.

Quick Decision Notes

AHT20 is indexed as a sensors part from Aosong. ChipScout tracks it by practical maker-facing dimensions: interfaces, library readiness, estimated price, field-level sources, and whether the page is strong enough for selection rather than only lookup.

Technical Specifications

MeasurementTemperature + humiditySource: Aosong
InterfaceI2CSource: Aosong
Address0x38Source: Aosong
Working Voltage2.0V - 5.5VSource: Aosong

Common Use Cases

  • Maker prototypes
  • Low-cost modules
  • Educational hardware

Known Issues

  • Breakout boards may use different pin labels or regulator choices
  • Clone modules can differ from the original datasheet part

Interfaces and Library Support

Interfaces
I2C
Wireless
None
Voltage
3.3V
Libraries
Arduino verifiedMicroPython verified
Data Integrity82% confidence
Sourcehttps://www.aosong.com/
Last verified2026-05-20
Core specsVerified
PinoutAvailable
Library supportChecked
Price rangePresent
Found a wrong spec?

Every field is meant to be source-backed. Corrections should include a datasheet URL, vendor page, module photo, or reproducible library test.

Submit correction

Source Resources

Pinout Table

VCC3V3 / VCCPower · 3.3V module · Check breakout regulator before using 5V.
GNDGNDPower · Common ground with controller.
SDASDABidirectional · Use board I2C data pin and pull-ups.
SCLSCLInput · Use board I2C clock pin.

Pinout is not yet source-verified. Use the table as an integration checklist, then confirm exact pins against the module vendor page before wiring hardware.

Common Wiring

VCC

Power · 3.3V module · Check breakout regulator before using 5V.

GND

Power · Common ground with controller.

SDA

Bidirectional · Use board I2C data pin and pull-ups.

SCL

Input · Use board I2C clock pin.

Arduino Example

#include <Wire.h>

void setup() {
  Serial.begin(115200);
  Wire.begin();
  Serial.println("AHT20 I2C scan");
}

void loop() {
  byte count = 0;
  for (byte address = 1; address < 127; address++) {
    Wire.beginTransmission(address);
    if (Wire.endTransmission() == 0) {
      Serial.print("Found I2C device at 0x");
      Serial.println(address, HEX);
      count++;
    }
  }
  Serial.print("Device count: ");
  Serial.println(count);
  delay(3000);
}

MicroPython Example

from machine import Pin, I2C
import time

i2c = I2C(0, scl=Pin(1), sda=Pin(0), freq=100000)
print("AHT20 I2C addresses:", [hex(x) for x in i2c.scan()])

while True:
    # Replace with the verified AHT20 driver read call.
    time.sleep(2)

Recommended Development Boards

ESP32-C3 sensor node

Low-cost Wi-Fi host for humidity telemetry.

Raspberry Pi Pico W

MicroPython-friendly I2C sensor target.

Qwiic/Stemma carrier

Useful for fast cable-based prototyping.

Alternative Model Reasons

SHT30SensorsUse when higher accuracy and better long-term stability are required.
BME280SensorsUse when pressure data is also needed.
ACS712SensorsCompare this option when price or module availability is the deciding constraint.
ADXL345SensorsThis alternative currently has stronger source coverage and confidence in ChipScout.

Common Questions

What is AHT20 best used for?

Projects needing I2C and Humidity with a commonly available sensors part.

Does AHT20 support Arduino or MicroPython?

AHT20 has verified Arduino support and verified MicroPython support.

What interfaces does AHT20 use?

AHT20 lists I2C; wireless support is no wireless protocol.

Compare AHT20 vs SHT30

Alternatives and Related Parts