⚠️ Affiliate Disclosure: This post contains Amazon affiliate links. If you purchase through our links, we may earn a small commission at no extra cost to you. Every product below was checked against its live Amazon listing before publishing. Prices change often, so we don’t list them here. Tap any Buy Here button to see the current price on Amazon.
ESP32 Motion Sensor Buying Guide
🧭 Best IMU and Accelerometer Sensors for ESP32
8 motion sensors, from the classic MPU-6050 to BNO085 sensor fusion, compared on axes, onboard fusion, interface and the ESP32 projects they actually suit.
✅ 8 Sensors Compared
✅ Verified Amazon ASINs
✅ 6-DoF vs 9-DoF Explained
✅ Honest Pros & Cons
Motion sensing turns up in more ESP32 projects than you might expect: self-balancing robots, gimbals, drone flight controllers, step counters and wearables, tilt alarms on gates and bins, vibration monitors on pumps and washing machines, and head trackers for VR or flight sims. The ESP32 has the speed and the I2C and SPI buses to read any of these sensors, but the chip you choose decides whether you get a clean, drift-free heading out of the box or spend a week tuning a complementary filter.
This guide compares 8 IMU and accelerometer boards: sensor fusion IMUs that output orientation directly (Adafruit BNO085 and BNO055, WitMotion WT901), raw 9-DoF IMUs (SparkFun ICM-20948, Adafruit LSM9DS1), 6-DoF IMUs (SparkFun LSM6DSO, the classic MPU-6050) and a dedicated 3-axis accelerometer (Adafruit ADXL345). For each we note axes, ranges, interface and how much maths the ESP32 has to do.
💡 Before you buy: Decide whether you need raw data or orientation. A 6-DoF or 9-DoF chip gives you accelerometer, gyroscope and (sometimes) magnetometer readings, and you write or borrow a fusion filter to turn them into roll, pitch and yaw. A fusion IMU like the BNO085 does that on board and hands the ESP32 a ready-made quaternion. Also remember that any magnetometer heading is thrown off by nearby motors, speakers, steel and current-carrying wires, so mount 9-DoF sensors away from them and calibrate in place.
⚡ Quick Comparison: All 8 Sensors
| Sensor | Type | Onboard Fusion | Interface | Best For | Buy |
|---|
| 🥇 Adafruit BNO085 | 9-DoF fusion IMU | Yes, quaternions and more | I2C / SPI / UART, STEMMA QT | Best Overall | Buy Here → |
| 🧭 Adafruit BNO055 | 9-DoF fusion IMU | Yes, Euler angles and quaternions | I2C | Easiest Absolute Orientation | Buy Here → |
| 🔋 SparkFun ICM-20948 | 9-DoF IMU | DMP (advanced) | I2C (Qwiic) / SPI | Best Low-Power 9-DoF | Buy Here → |
| ⚡ SparkFun LSM6DSO | 6-DoF IMU | No (motion events on chip) | I2C (Qwiic) / SPI | Best Fast 6-DoF | Buy Here → |
| 🧲 Adafruit LSM9DS1 | 9-DoF IMU | No | I2C / SPI | Best for Learning Fusion | Buy Here → |
| 📳 Adafruit ADXL345 | 3-axis accelerometer | No (tap and free-fall detect) | I2C / SPI | Best for Tilt and Vibration | Buy Here → |
| 🎓 HiLetgo GY-521 MPU-6050 | 6-DoF IMU | DMP (advanced) | I2C | Best Budget | Buy Here → |
| 📐 WitMotion WT901 | 9-axis AHRS module | Yes, Kalman filtered angles | TTL serial / I2C | Best Ready-Made Inclinometer | Buy Here → |
Specs come from the manufacturers and the live Amazon listings. Star scores below are our ratings.
🔍 What Matters in an IMU for ESP32
🧮
Onboard Sensor Fusion
Fusion IMUs output stable orientation directly. Raw IMUs need a Madgwick, Mahony or Kalman filter running on the ESP32, plus calibration.
🧲
6-DoF or 9-DoF
6-DoF gives roll and pitch but yaw slowly drifts. A magnetometer (9-DoF) anchors heading to north, as long as there’s no magnetic interference nearby.
🔌
Interface and Connectors
I2C shares two pins with your display and other sensors; SPI is faster and more robust. Qwiic and STEMMA QT boards plug in with no soldering.
📈
Range and Data Rate
Pick ±2 g for gentle tilt and ±16 g for impacts. Vibration analysis and drones want kilohertz output rates; a tilt alarm is fine at 10 Hz.
💤
Wake-on-Motion
Battery projects benefit from chips that raise an interrupt on tap, free fall or movement, so the ESP32 can sleep until something happens.
🏆 Detailed Reviews: The Top Two
🥇 BEST OVERALL IMU FOR ESP32
Adafruit 9-DOF Orientation IMU Fusion Breakout, BNO085
⭐ 4.8/5 · Our Rating · Fusion Done For You
Quaternions
ONBOARD FUSION
I2C / SPI / UART
INTERFACE
Buy on Amazon →

The BNO085 combines an accelerometer, gyroscope and magnetometer with a processor running CEVA’s sensor fusion firmware, so the ESP32 never has to run a filter. Instead of raw numbers it reports rotation vectors as quaternions (absolute, game and geomagnetic versions), plus linear acceleration, gravity, a step counter, stability and activity classifiers, and tap and shake detection. Adafruit’s breakout adds STEMMA QT connectors and exposes I2C, SPI and UART, including a simple UART-RVC mode that streams heading, pitch and roll with no library at all. Adafruit’s BNO08x library supports the ESP32 in Arduino. For the most reliable link, SPI or UART is a good choice on the ESP32, since the chip is picky about I2C timing.
✅ Pros- Stable orientation out of the box
- Rich outputs: steps, activity, taps
- I2C, SPI, UART and UART-RVC
- Solderless STEMMA QT
❌ Cons- Fusion firmware is a black box
- I2C can be finicky on ESP32
- Pricier than raw IMUs
🎯 Verdict: The best IMU for ESP32 projects that need accurate orientation without writing a fusion filter.
👉 Check Price on Amazon →
🧭 EASIEST ABSOLUTE ORIENTATION SENSOR
Adafruit 9-DOF Absolute Orientation IMU Fusion Breakout, BNO055
⭐ 4.6/5 · Our Rating · The Proven Classic
Buy on Amazon →

Bosch’s BNO055 was the first hobby-friendly IMU with fusion built in, and it’s still one of the simplest to use. An onboard ARM Cortex-M0 merges the three sensors and outputs Euler angles (heading, roll, pitch), quaternions, linear acceleration, the gravity vector and temperature at 100 Hz. Euler angles in degrees are exactly what most beginners want for a tilt display or a pan-tilt camera. It also reports calibration status for each sensor, so you can save offsets and restore them at boot. Adafruit’s board includes a regulator and runs from 3 to 5 V. The chip uses I2C clock stretching, so if you see read errors on an ESP32, drop the bus to 100 kHz.
✅ Pros- Euler angles in degrees, no maths
- Calibration status reporting
- Huge library and tutorial base
- Simple I2C wiring
❌ Cons- Older than the BNO085
- Clock stretching quirks
- Heading needs calibration in place
🎯 Verdict: The easiest way to read real angles in degrees from an ESP32, with years of examples behind it.
👉 Check Price on Amazon →
🔧 Detailed Reviews: Raw IMUs and Accelerometers
🔋 BEST LOW-POWER 9-DOF · ⭐ 4.6/53. SparkFun 9DoF IMU Breakout, ICM-20948 (Qwiic)
±2 to ±16 g · ±250 to ±2000 dps · ±4900 µT magnetometer · I2C (Qwiic) / SPI · 3.3 V
Buy Here →

TDK InvenSense’s ICM-20948 is the modern successor to the MPU-9250 and one of the lowest-power 9-axis chips around, which makes it a good match for battery ESP32 wearables and trackers. It packs a 3-axis accelerometer, gyroscope and AK09916 magnetometer, plus a Digital Motion Processor that can run fusion on chip if you enable it in SparkFun’s library. SparkFun’s board handles the level shifting, adds Qwiic connectors and breaks out SPI and the interrupt pin, and the library includes ESP32-tested examples.
✅ Pros: Low power; full 9-DoF; Qwiic and SPI; optional DMP fusion.
❌ Cons: DMP setup is more involved than a BNO.
🎯 Verdict: The best raw 9-DoF IMU for battery-powered ESP32 wearables and trackers.
⚡ BEST FAST 6-DOF · ⭐ 4.5/54. SparkFun 6 Degrees of Freedom Breakout, LSM6DSO (Qwiic)
±2 to ±16 g · ±125 to ±2000 dps · up to 6.66 kHz · I2C (Qwiic) / SPI · 3.3 V
Buy Here →

ST’s LSM6DSO is a modern, accurate 6-axis IMU with output rates up to 6.66 kHz, a large FIFO buffer and built-in motion events: tap, double tap, free fall, wake-up, tilt and a pedometer, each able to raise an interrupt. That combination suits balancing robots and flight controllers that need fast, low-noise gyro data, and battery devices that want to sleep until moved. SparkFun’s board adds Qwiic connectors and SPI pins, and its Arduino library works on the ESP32.
✅ Pros: Fast, low noise; FIFO; motion interrupts; Qwiic.
❌ Cons: No magnetometer, so yaw drifts.
🎯 Verdict: A big step up from the MPU-6050 for robots, gimbals and wake-on-motion gadgets.
🧲 BEST FOR LEARNING SENSOR FUSION · ⭐ 4.4/55. Adafruit 9-DOF Accel/Mag/Gyro+Temp Breakout, LSM9DS1
±2 to ±16 g · ±245 to ±2000 dps · ±4 to ±16 gauss · I2C / SPI · 3 to 5 V
Buy Here →

The LSM9DS1 gives you all nine raw axes from ST in one package, with selectable ranges on each sensor and a temperature reading. Because it does no fusion itself, it’s an excellent board for learning how a Madgwick or Mahony filter works on the ESP32, and plenty of open-source AHRS code targets it. Adafruit’s breakout adds a regulator and level shifting so it’s happy on 3.3 V or 5 V, and exposes both I2C and SPI. It’s the same chip used on the Arduino Nano 33 BLE, so many examples carry over.
✅ Pros: Full 9-DoF raw data; I2C or SPI; lots of AHRS examples.
❌ Cons: You write the fusion and calibration yourself.
🎯 Verdict: The pick for makers who want to understand and tune their own orientation filter.
📳 BEST FOR TILT AND VIBRATION · ⭐ 4.5/56. Adafruit ADXL345 Triple-Axis Accelerometer
±2 / 4 / 8 / 16 g · up to 13-bit · tap, free-fall and activity interrupts · I2C / SPI · 3 to 5 V
Buy Here →

Not every project needs a gyroscope. If you want to know whether a gate is open, a bin has tipped over, a parcel was dropped or a pump is vibrating harder than usual, a plain accelerometer is simpler and cheaper to run. Analog Devices’ ADXL345 measures up to ±16 g and has hardware detection for tap, double tap, free fall and activity or inactivity, each routable to an interrupt pin so the ESP32 can deep sleep until it fires. It’s also the accelerometer Klipper uses for 3D printer resonance testing, so it’s well proven for vibration work. Adafruit’s board supports I2C and SPI and has a regulator for 3 to 5 V.
✅ Pros: Hardware tap and free-fall interrupts; ±16 g; I2C or SPI.
❌ Cons: No gyro, so no smooth orientation while moving.
🎯 Verdict: The right sensor for tilt alarms, knock detection and vibration monitoring on battery power.
➕ Also Worth Considering
🎓 BEST BUDGET · ⭐ 4.2/5
7. HiLetgo GY-521 MPU-6050 6-Axis Accelerometer Gyroscope Module
The MPU-6050 is the IMU almost every ESP32 tutorial starts with: a 3-axis accelerometer (±2 to ±16 g) and 3-axis gyroscope (±250 to ±2000 dps) with 16-bit converters on I2C, on a GY-521 board with its own regulator. It’s very cheap and supported everywhere, including ESPHome. The original InvenSense part is no longer in production, so boards vary and some carry clone chips; it’s fine for learning and balance robots, but pick the LSM6DSO for anything you want to rely on.
Buy Here →📐 BEST READY-MADE INCLINOMETER · ⭐ 4.3/5
8. WitMotion WT901 9-Axis AHRS Inclinometer Module
The WT901 is a small 9-axis module (MPU9250 based, per the listing) with its own microcontroller running a Kalman filter, so it outputs angles, angular rate, acceleration and magnetic field over TTL serial or I2C at 0.2 to 200 Hz. WitMotion quotes 0.05 degree X and Y angle accuracy when static, and the module runs from 3.3 to 5 V. Connect it to a spare ESP32 hardware UART and parse its simple packets. It’s a good fit for leveling platforms, solar tracker tilt and machine inclination readouts.
Buy Here →🛠️ Which Sensor for Which ESP32 Project?
| Project | What You Need | Best Pick |
|---|
| Head tracker, VR or camera gimbal | Smooth, drift-free 3D orientation | Adafruit BNO085 |
| Tilt display, pan-tilt camera, compass | Angles in degrees, simple code | Adafruit BNO055 |
| Self-balancing robot | Fast gyro and accel, low latency | SparkFun LSM6DSO or MPU-6050 |
| Wearable, step counter, asset tracker | Low power, wake-on-motion | SparkFun ICM-20948 or BNO085 |
| Gate, bin or door tilt alarm | Tilt and activity interrupts | Adafruit ADXL345 |
| Pump or washer vibration monitor | High g range, fast sampling | Adafruit ADXL345 or LSM6DSO |
| Learning AHRS and filters | Raw 9-axis data | Adafruit LSM9DS1 |
| Platform leveling, solar tracker tilt | Accurate static angles over UART | WitMotion WT901 |
🛒 Which One Should You Buy?
🎓
Just learning
The HiLetgo MPU-6050 for your first readings, then the LSM9DS1 to learn fusion.
🧭
Want orientation now
The BNO085 for the best results, or the BNO055 for the simplest code.
🤖
Robots and drones
The LSM6DSO for fast, low-noise 6-axis data on Qwiic or SPI.
🔋
Battery and smart home
The ADXL345 for tilt and knock alarms, the ICM-20948 for low-power 9-DoF.
❓ Frequently Asked Questions
What is the difference between an accelerometer, a 6-DoF and a 9-DoF IMU?
An accelerometer measures acceleration and gravity, which gives tilt when still. A 6-DoF IMU adds a gyroscope for smooth rotation tracking while moving. A 9-DoF IMU adds a magnetometer so heading (yaw) can be referenced to magnetic north instead of drifting over time.
Why does my yaw angle keep drifting?
Gyroscopes have a small bias, and integrating it over time adds up. Gravity corrects roll and pitch, but nothing corrects yaw on a 6-DoF IMU. Use a 9-DoF sensor with a calibrated magnetometer, or a fusion IMU like the BNO085 whose game rotation vector keeps drift low for short sessions.
Do these IMUs work with 3.3 V ESP32 boards?
Yes. All eight picks run on 3.3 V, and the Adafruit, SparkFun and GY-521 boards include regulators or level shifting. Power them from the ESP32’s 3.3 V pin (or 5 V where the board has a regulator) and connect SDA and SCL to your I2C pins. Many ESP32 dev boards with a Qwiic or STEMMA QT port need no soldering at all.
Can I use an IMU with ESPHome and Home Assistant?
ESPHome has built-in components for the MPU-6050 and some other IMUs, which report acceleration and gyro values as sensors. That’s ideal for tilt and vibration automations, like a garage door position or a washing machine finished alert. Full 3D orientation from fusion IMUs usually needs custom code.
How do I calibrate the magnetometer?
Calibrate with the sensor mounted in its final enclosure, away from motors and steel. Slowly rotate the whole device through every orientation (a figure-eight motion works) so the software can measure hard and soft iron offsets. The BNO055 and BNO085 do this automatically and report their calibration status; save the offsets so you don’t repeat it at every boot.
🏁 Final Verdict: Best IMU and Accelerometer Sensors for ESP32
The right motion sensor for each job:
🧭 Easiest Absolute Orientation: Adafruit BNO055
Buy Here →🔋 Best Low-Power 9-DoF: SparkFun ICM-20948
Buy Here →📳 Best for Tilt and Vibration: Adafruit ADXL345
Buy Here →For most ESP32 builds, the Adafruit BNO085 is the IMU to start with: accurate orientation as quaternions with no filter to write. Choose the BNO055 if you want angles in degrees with the simplest code, the ICM-20948 for low-power 9-DoF wearables, the LSM6DSO for fast robot and gimbal loops, the LSM9DS1 to learn sensor fusion, the ADXL345 for tilt and vibration alarms, the MPU-6050 for first experiments and the WitMotion WT901 for a ready-made inclinometer. For more parts, see our best sensors for ESP32 roundup, the distance sensors for ESP32 guide, the ESP32 robot kits and motor drivers guide and our ESP32 pocket and wearable dev kits comparison.
💬 Not sure which motion sensor fits your project? Tell us what you’re building and whether you need tilt, rotation or heading in the comments below, and we’ll point you to the right one.
All Amazon links above use our affiliate tag (esp32tutorials-20). Purchasing through them supports esp32tutorials.com at no extra cost to you. Prices and availability change frequently, so always confirm the current price on Amazon before buying.
We are a team of experienced Embedded Software Developers with skills in developing Embedded Linux, RTOS, and IoT products from scratch to deployment with a demonstrated history of working in the embedded software industry. Contact us for your projects: admin@esp32tutorials.com