Components / Sensors / AHT20 temperature and humidity sensor

AHT20 temperature and humidity sensor

Small, cheap I2C humidity sensor, a good DHT replacement.

MeasuresTemperature and relative humidity
Accuracy±0.3 °C, ±2 % RH
InterfaceI2C
I2C address0x38
SensorsReviewedMPN AHT20Used in 18 projects
AHT20
In short

What is the AHT20 temperature and humidity sensor and what is it used for?

Small, cheap I2C humidity sensor, a good DHT replacement. Makers use it for room monitors.

How it works

A capacitive humidity element and temperature sensor are read by an on-chip ADC and calibrated at the factory.

Key specifications

Sensor specValue
MeasuresTemperature and relative humidity
Accuracy±0.3 °C, ±2 % RH
InterfaceI2C
I2C address0x38
Supply voltage2.0 to 5.5 V

Pinout

VIN2 to 5.5 V
GNDGround
SCLI2C clock
SDAI2C data

How to use it

Use the Adafruit AHTX0 library at address 0x38. Mount it away from the microcontroller and regulator. AHT20 boards are often combined with a BMP280 on one module to add pressure.

Applications

Alternatives

Buy at

Common questions

What is the AHT20 temperature and humidity sensor used for?

In maker projects: room monitors.

How does the AHT20 temperature and humidity sensor work?

A capacitive humidity element and temperature sensor are read by an on-chip ADC and calibrated at the factory.

What voltage does the AHT20 temperature and humidity sensor need?

2.0 to 5.5 V.

How do I connect the AHT20 temperature and humidity sensor to an Arduino or ESP32?

I2C. Pins: VIN (2 to 5.5 V), GND (Ground), SCL (I2C clock), SDA (I2C data).

What can I use instead of the AHT20 temperature and humidity sensor?

SHT31 temperature and humidity sensor and DHT22 Sensor.