BME280 heating up over time


I have BME280 sensor and I observe that it readings are inacurrate over time - it looks like its heating up over time, and finally it can shows temperature ~5C higher than on the beggining of measurements.
Please look at attached chart. It shows how BME280 increasing temperature when it is turn on after some time of cooling.
Here are links where I found that it can require to slow down readings, but I don’t know how to do this:

I use code as below:

#include <Wire.h>
#include <SPI.h>
#include <Adafruit_Sensor.h>
#include <Adafruit_BME280.h>

#define BME_SCK 13
#define BME_MISO 12
#define BME_MOSI 11
#define BME_CS 10

#define SEALEVELPRESSURE_HPA (1013.25)

Adafruit_BME280 bme; // I2C

unsigned long delayTime;

void setup() {
    Serial.println(F("BME280 test"));

    if (! bme.begin(&Wire)) {
        Serial.println("Could not find a valid BME280 sensor, check wiring!");
        while (1);

    Serial.println("-- Default Test --");
    Serial.println("normal mode, 16x oversampling for all, filter off,");
    Serial.println("0.5ms standby period");
    delayTime = 5000;
    // indoor navigation
    Serial.println("-- Indoor Navigation Scenario --");
    Serial.println("normal mode, 16x pressure / 2x temperature / 1x humidity oversampling,");
    Serial.println("0.5ms standby period, filter 16x");
                    Adafruit_BME280::SAMPLING_X2,  // temperature
                    Adafruit_BME280::SAMPLING_X16, // pressure
                    Adafruit_BME280::SAMPLING_X1,  // humidity
    delayTime = 5000;

void loop() {
    // Only needed in forced mode! In normal mode, you can remove the next line.
    bme.takeForcedMeasurement(); // has no effect in normal mode

void printValues() {
    //Serial.print("Temperature = ");
    //Serial.println(" *C");

Please someone help me with this. I’m working on it few days, but Im newbee to Arduino and can’t understand what should I change.


Post links to the module, and a hand drawn (not Fritzing) wiring diagram.

Such behavior is not normal, and the sensor may be defective, or you may have miswired it.

Are you running it at the correct voltage ? A stand alone sensor needs 3.3v .
Some on break out boards have regulators to allow 5v operation.

Where is the sensor in relation to the Arduino? As little as it is the heat from a powered Arduino will probably do this if it's close or enclosed with the BME280, especially if the Arduino is an ESP variant.

PCB heating up due to other more power hungry chips? PCB heating up because you are standing
over it and radiating body heat at it? (Can be a significant effect, although 5 degrees is a lot for this).

I'm also thinking heating due to waste heat from nearby electronics.
5 degrees is indeed a bit much (expect 1-3 degrees) but add an enclosure and it's becoming plausible.