Component guide · Intermediate · 4 min read
BME680 Environmental Sensor

Pinout, Wiring and Code
By Geekobot Learning Team · Updated 29 Oct 2026
On this page
The BME680 from Bosch measures temperature, humidity, air pressure and volatile organic compounds (VOC) in one small chip. It talks I2C (address 0x76 or 0x77) or SPI. The gas sensor gives a resistance that falls as VOC levels rise; Bosch's BSEC library turns that into an indoor air quality (IAQ) index. Use it for room air monitors and weather stations.
Key specs at a glance
- Measures
- Temperature, relative humidity, barometric pressure, VOC gas (as resistance)
- Temperature
- −40 to 85 °C, ±1 °C
- Humidity
- 0 to 100 % RH, ±3 %
- Pressure
- 300 to 1100 hPa, ±0.6 hPa
- Interface
- I2C (0x76 or 0x77) or SPI
- Supply
- Chip 1.71 to 3.6 V; most modules 3.3 to 5 V
Models in this guide
These are alternatives. Pick the one that fits your project; you only need one.
Option 1Bosch BME680 4-in-1 Environmental Sensor (Temperature, Humidity, Pressure & VOC Gas) – I2C/SPI₹1,149
Option 2Bosch BME680 4-in-1 Environmental Sensor Module – Temperature, Humidity, Pressure, Gas (VOC), I²C/SPI₹1,089
Option 3Bosch BME680 Digital Temperature Humidity Pressure VOC Gas Sensor Module CJMCU-680 Development Board – I2C/SPI Interface₹829
Option 4DFRobot Fermion BME680 Environmental Sensor Breakout – I2C/SPI, 3.3V/5V₹1,989
Option 5DFRobot Gravity I2C BME680 Environmental Sensor – Temperature, Humidity, Pressure & VOC₹1,889
Option 6Seeed Studio Grove BME680 Temperature Humidity Pressure Gas Sensor Module₹2,369
What the BME680 is
The BME680 combines the temperature, humidity and pressure sensing of the BME280 with a tiny heated metal-oxide gas sensor. The heater burns off gases on the sensing layer, and its resistance shows how much VOC (from paints, cleaning sprays, cooking and breathing) is in the air.
The raw gas resistance is relative: it changes with humidity and drifts slowly. For a calibrated IAQ index and CO2 equivalent, use Bosch's BSEC library, which learns the sensor's baseline over a few days.
BME680 pinout
The pins on the BME680 and what each one does.
| Pin | Function |
|---|---|
| VCC / VIN | Supply, 3.3 to 5 V on modules with a regulator |
| GND | Ground |
| SCL / SCK | I2C clock, or SPI clock |
| SDA / SDI | I2C data, or SPI data in |
| SDO | I2C address select (GND 0x76, VCC 0x77), or SPI data out |
| CS | SPI chip select; high (or open) for I2C |
- VCC / VIN
- Supply, 3.3 to 5 V on modules with a regulator
- GND
- Ground
- SCL / SCK
- I2C clock, or SPI clock
- SDA / SDI
- I2C data, or SPI data in
- SDO
- I2C address select (GND 0x76, VCC 0x77), or SPI data out
- CS
- SPI chip select; high (or open) for I2C
Wiring the BME680
CJMCU-680 and many blue modules answer at 0x76; Adafruit, DFRobot and some Waveshare boards default to 0x77. The code below tries both.
| BME680 pin | Arduino Uno | ESP32 |
|---|---|---|
| VCC | 5V (or 3.3V) | 3V3 |
| GND | GND | GND |
| SDA | A4 | GPIO 21 |
| SCL | A5 | GPIO 22 |
| SDO | GND (0x76) or VCC (0x77) | GND (0x76) or VCC (0x77) |
- VCC
- Arduino Uno:
- 5V (or 3.3V)
- ESP32:
- 3V3
- GND
- Arduino Uno:
- GND
- ESP32:
- GND
- SDA
- Arduino Uno:
- A4
- ESP32:
- GPIO 21
- SCL
- Arduino Uno:
- A5
- ESP32:
- GPIO 22
- SDO
- Arduino Uno:
- GND (0x76) or VCC (0x77)
- ESP32:
- GND (0x76) or VCC (0x77)
Example code
Higher gas resistance means cleaner air. Let it run for 30 minutes or more before comparing readings, and compare against its own baseline, not a fixed number.
#include <Wire.h>
#include <Adafruit_Sensor.h>
#include "Adafruit_BME680.h"
Adafruit_BME680 bme; // also works with the BME688
void setup() {
Serial.begin(115200);
if (!bme.begin(0x76) && !bme.begin(0x77)) { Serial.println("No sensor at 0x76 or 0x77"); while (1); }
bme.setTemperatureOversampling(BME680_OS_8X);
bme.setHumidityOversampling(BME680_OS_2X);
bme.setPressureOversampling(BME680_OS_4X);
bme.setGasHeater(320, 150); // 320 °C for 150 ms
}
void loop() {
if (!bme.performReading()) return;
Serial.print(bme.temperature); Serial.print(" C ");
Serial.print(bme.humidity); Serial.print(" % ");
Serial.print(bme.pressure / 100.0); Serial.print(" hPa gas ");
Serial.print(bme.gas_resistance / 1000.0); Serial.println(" kOhm");
delay(3000);
}Setup and tuning
a new sensor stabilises over the first 48 hours of running.
the gas heater warms the chip; read temperature less often or use a lower duty cycle if temperature accuracy matters.
Bosch BSEC (BSEC2 for the Arduino IDE) gives IAQ 0 to 500 and estimated CO2; it needs more memory than an Uno has, so use an ESP32.
keep it out of direct airflow from fans and away from the board's regulator.
What you need
Shop this list12 of 13 found in our store · ₹14,958
Bosch BME680 4-in-1 environmental sensor: the sensor this guide coversBosch BME680 4-in-1 Environmental Sensor (Temperature, Humidity, Pressure & VOC Gas) – I2C/SPI₹1,149Closest match, check the specs
Bosch BME680 4-in-1 Environmental Sensor Module – Temperature, Humidity, Pressure, Gas (VOC), I²C/SPI: another version this guide coversBosch BME680 4-in-1 Environmental Sensor Module – Temperature, Humidity, Pressure, Gas (VOC), I²C/SPI₹1,089
Bosch BME680 Digital Temperature Humidity Pressure VOC Gas Sensor Module CJMCU-680 Development Board – I2C/SPI Interface: another version this guide coversBosch BME680 Digital Temperature Humidity Pressure VOC Gas Sensor Module CJMCU-680 Development Board – I2C/SPI Interface₹829
DFRobot Fermion BME680 Environmental Sensor Breakout – I2C/SPI, 3.3V/5V: another version this guide coversDFRobot Fermion BME680 Environmental Sensor Breakout – I2C/SPI, 3.3V/5V₹1,989
DFRobot Gravity I2C BME680 Environmental Sensor – Temperature, Humidity, Pressure & VOC: another version this guide coversDFRobot Gravity I2C BME680 Environmental Sensor – Temperature, Humidity, Pressure & VOC₹1,889
Seeed Studio Studio Grove BME680 Temperature Humidity Pressure Gas Sensor Module: another version this guide coversSeeed Studio Grove BME680 Temperature Humidity Pressure Gas Sensor Module₹2,369Closest match, check the specs
Waveshare BME680 Environmental Sensor Module – I2C/SPI Interface, 3.3V/5V Compatible: another version this guide coversWaveshare BME680 Environmental Sensor Module – I2C/SPI Interface, 3.3V/5V Compatible₹1,229
BME680 White Shell Built-in Cotton Core with Card Holder 1 Meter Cable – I2C: another version this guide coversBME680 White Shell Built-in Cotton Core with Card Holder 1 Meter Cable – I2C₹2,139
BME680 Stainless Steel Probe Wire 1 Meter – I2C Interface: another version this guide coversBME680 Stainless Steel Probe Wire 1 Meter – I2C Interface₹1,699
ESP32-WROOM-32 38-pin development board: for Wi-Fi logging and dashboardsESP32-WROOM-32 38-Pin Development Board₹389- Uno R3 development board: the controller used in the wiring tableFind this part
0.96 inch OLED display 128x64: to show readings without a computer0.96" OLED Display 128x64₹139Closest match, check the specs
Dupont jumper wires: for the connectionsDupont Jumper Wires (40 pcs)₹49Closest match, check the specs
Alternatives and when to choose them
- BME688: same pinout, adds gas scanning for AI gas detection.
- BME280 vs BMP280: no gas sensor, lower cost.
- VOC and indoor air quality sensors: SGP40, ENS160 and MQ types compared.
- CO2 sensors: for true CO2, use an NDIR sensor.
Try it: I2c pullup calculator
Change the values and the diagram and results update as you type.
Common mistakes to avoid
- Treating the gas resistance as ppm of a specific gas.
- Expecting real CO2 values; the BME680 estimates CO2 equivalent from VOC.
- Reading it right after power-up, before the heater has settled.
- Trying to run BSEC on an Arduino Uno.
Frequently asked questions
What is the BME680's I2C address?
0x76 with SDO to GND or 0x77 with SDO to VCC.
Does the BME680 measure CO2?
No. It measures VOCs; BSEC estimates a CO2 equivalent. Use an NDIR sensor such as the SCD40 for real CO2.
BME680 or BME688?
The BME688 is the newer version with gas scanning for AI classification; for normal IAQ readings they behave the same.
Why does the gas reading keep changing?
The sensor needs time to settle, and humidity changes affect it. BSEC compensates for this.
Does it work at 5 V?
Modules with a regulator do. The bare chip is 3.3 V.
Parts for this guide
- ₹1,149View
Bosch BME680 4-in-1 Environmental Sensor Module – Temperature, Humidity, Pressure, Gas (VOC), I²C/SPI₹1,089View
Bosch BME680 Digital Temperature Humidity Pressure VOC Gas Sensor Module CJMCU-680 Development Board – I2C/SPI Interface₹829View- ₹1,989View
- ₹1,889View
- ₹2,369View
- ₹1,229View
- ₹2,139View
- ₹1,699View
- ₹389View
- ₹359View
- ₹139View
- ₹49View
Calculators
Terms in this guide
Projects that use it
Put this into practice: 3 step-by-step builds in our project library use parts from this guide.
Keep learning
Sources
- BME680 low power gas, pressure, temperature and humidity sensor datasheet (Bosch Sensortec)
- Adafruit BME680 library
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.

