Best Light Sensors for ESP32: 8 VEML7700, TSL2591, VEML6030, LTR390 UV, AS7341, APDS9960 and BH1750 Picks Compared (Buying Guide)

⚠️ 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 Sensor Buying Guide

β˜€οΈ Best Light Sensors for ESP32

Lux meters, UV index sensors, spectral colour sensors and gesture boards: 8 I2C light sensors that work with ESP32, Arduino and ESPHome, compared on range, features and real use cases.

βœ… 8 Sensors Compared βœ… Verified Amazon ASINs βœ… Lux, UV and Spectral βœ… ESPHome Friendly

Light sensors are some of the most useful parts you can wire to an ESP32. They dim displays and LED strips automatically, switch on porch lights at dusk, log daylight in a greenhouse, report the UV index on a weather station and even tell colours apart on a sorting machine. A cheap photoresistor on an analog pin can tell light from dark, but it drifts with temperature, needs calibration and the ESP32’s ADC is not very linear, so you never get a real lux value out of it.

The digital I2C sensors in this guide do the conversion on-chip and hand your ESP32 calibrated readings over two wires. We compared 8 sensors: general-purpose lux sensors (VEML7700, VEML6030, BH1750), a very high dynamic range sensor (TSL2591), UV sensors (LTR390), a spectral colour sensor (AS7341) and a combined proximity, colour and gesture sensor (APDS9960). All of them have mature Arduino libraries, and most are supported directly in ESPHome.

πŸ’‘ Before you buy: Decide what you actually need to measure. For indoor brightness and auto-dimming, any lux sensor works. For direct sunlight, check the top of the range (the BH1750 saturates around 65,000 lux, while full summer sun can exceed 100,000 lux). For very dark rooms or night sky, low-end sensitivity matters more, which is where the TSL2591 shines. A UV sensor or colour sensor will not replace a lux sensor, and a sensor behind a tinted or frosted enclosure window will always read low, so plan a clear window and calibrate in place.

⚑ Quick Comparison: All 8 Light Sensors

SensorTypeRange / ChannelsConnectorBest ForBuy
πŸ₯‡ Adafruit VEML7700Ambient lux0 to ~120,000 lux, 16-bitSTEMMA QTBest OverallBuy Here β†’
πŸŒ™ Adafruit TSL2591Lux + IR188 Β΅lux to 88,000 luxSTEMMA QTBest for Low LightBuy Here β†’
πŸ”Œ SparkFun VEML6030Ambient lux0 to ~120,000 lux, 16-bitQwiicBest Qwiic Lux SensorBuy Here β†’
πŸ•ΆοΈ Adafruit LTR390UV + ambient lightUV counts to UV Index, plus luxSTEMMA QTBest UV SensorBuy Here β†’
🌈 Waveshare AS7341Spectral colour8 visible bands + clear, NIR, flickerI2C headerBest Spectral SensorBuy Here β†’
πŸ‘‹ Adafruit APDS9960Proximity, RGB, gestureRGB + clear light, gesturesSTEMMA QTBest for GesturesBuy Here β†’
πŸ’° SHILLEHTEK BH1750Ambient lux1 to 65,535 lux, 16-bitPin headerBest BudgetBuy Here β†’
β˜€οΈ Waveshare LTR390-UV (C)UV + ambient lightUV index and lux outputI2C headerBudget UV PickBuy Here β†’

Specs come from the manufacturers and the live Amazon listings. Star scores below are our ratings.

πŸ” What Matters in an ESP32 Light Sensor

πŸ“ˆ

Lux Range

Indoor rooms sit around 100 to 1,000 lux, overcast daylight several thousand, and direct sun can top 100,000. Pick a sensor whose range covers your brightest case.

πŸŒ™

Low-Light Sensitivity

Dusk detection and night logging need resolution well below 1 lux. Adjustable gain and integration time let one sensor cover dark and bright scenes.

πŸ‘οΈ

Human Eye Response

Good lux sensors filter their response to match the human eye, so a bright IR source like an incandescent bulb or the sun does not inflate the reading.

πŸ”—

I2C Address and Connector

STEMMA QT and Qwiic boards plug in with one cable and chain with other sensors. Check the I2C address so it does not clash with sensors already on the bus.

🏠

Library and ESPHome Support

All picks here have Arduino libraries. VEML7700, TSL2591, BH1750, LTR390, AS7341 and APDS9960 also have native ESPHome components.

πŸ† Detailed Reviews: The Top Two

πŸ₯‡ BEST OVERALL LIGHT SENSOR

Adafruit VEML7700 Lux Sensor

⭐ 4.8/5 · Our Rating · The Default Choice
120k
LUX MAX
16-bit
RESOLUTION
0x10
I2C ADDRESS
3 to 5V
POWER
Buy on Amazon β†’
Adafruit VEML7700 Lux Sensor for ESP32

If you only buy one light sensor for ESP32 projects, make it the VEML7700. This Vishay sensor measures from near darkness up to roughly 120,000 lux with 16-bit resolution, so the same board handles a dim bedroom and full sunlight. Its photodiode response is filtered to match the human eye, which means readings line up with what you see rather than spiking under IR-heavy light. Adafruit’s breakout adds a regulator and level shifting, so it runs from 3.3V or 5V, and STEMMA QT connectors let you chain it with other sensors without soldering. Gain and integration time are adjustable, and both the Adafruit library and ESPHome’s veml7700 component handle the auto-ranging for you.

βœ… Pros
  • Covers dark rooms to direct sun
  • Human eye matched response
  • Plug-and-play STEMMA QT
  • Native ESPHome support
❌ Cons
  • Fixed I2C address (0x10)
  • Needs auto-gain for best low-light results
🎯 Verdict: The best all-round lux sensor for auto-dimming, dusk switches and daylight logging.

πŸ‘‰ Check Price on Amazon β†’

πŸŒ™ BEST FOR LOW LIGHT AND HIGH DYNAMIC RANGE

Adafruit TSL2591 High Dynamic Range Light Sensor

⭐ 4.7/5 · Our Rating · Most Sensitive
188 Β΅lux
MIN READING
88k lux
MAX READING
600M:1
DYNAMIC RANGE
IR + Full
DIODES
Buy on Amazon β†’
Adafruit TSL2591 High Dynamic Range Light Sensor for ESP32

The TSL2591 is the sensor to pick when darkness matters. It resolves light levels as low as 188 micro-lux and still reads up to 88,000 lux, a dynamic range of about 600,000,000 to 1. It has separate full-spectrum and infrared photodiodes, so the library can subtract IR and calculate a lux value close to human vision, or give you the raw IR reading for plant and IR experiments. That sensitivity makes it ideal for sky-quality meters, night-time logging, astronomy projects and dusk detection that must not flicker at twilight. The STEMMA QT version runs from 3.3V or 5V and uses I2C address 0x29.

βœ… Pros
  • Exceptional low-light sensitivity
  • Separate IR and full-spectrum readings
  • Huge dynamic range
  • STEMMA QT and ESPHome support
❌ Cons
  • Tops out below full summer sun
  • Fixed I2C address (0x29)
🎯 Verdict: The best choice for dark scenes, night logging and twilight switching.

πŸ‘‰ Check Price on Amazon β†’

πŸ”¬ Detailed Reviews: Lux, UV, Spectral and Gesture Sensors

πŸ”Œ BEST QWIIC LUX SENSOR Β· ⭐ 4.6/5

3. SparkFun Ambient Light Sensor VEML6030 (Qwiic)

VEML6030 Β· 0 to ~120,000 lux Β· 16-bit Β· Qwiic Β· selectable I2C address Β· interrupt pin
Buy Here β†’
SparkFun Ambient Light Sensor VEML6030 (Qwiic) for ESP32

SparkFun’s VEML6030 board is the Qwiic-ecosystem counterpart to the VEML7700, using a closely related Vishay sensor with the same 16-bit resolution and a range up to roughly 120,000 lux. Two things set it apart: a jumper lets you change the I2C address, so you can run two on one bus (for example, one indoors and one facing a window), and an interrupt pin can wake your ESP32 when light crosses a threshold, which is useful for battery-powered deep-sleep projects. It is a 3.3V board, which suits the ESP32 perfectly.

βœ… Pros: Address jumper; threshold interrupt; Qwiic chaining; SparkFun library.
❌ Cons: 3.3V only; no native ESPHome component (use a custom component or the VEML7700 instead).
🎯 Verdict: The best lux sensor when you need two on one bus or an interrupt for deep sleep.
πŸ•ΆοΈ BEST UV SENSOR Β· ⭐ 4.6/5

4. Adafruit LTR390 UV Light Sensor

LTR390 Β· UV and ambient light modes Β· UV Index from raw counts Β· STEMMA QT Β· I2C 0x53 Β· 3 to 5V
Buy Here β†’
Adafruit LTR390 UV Light Sensor for ESP32

For a weather station, a garden monitor or a “should I wear sunscreen” display, the LTR390 is the modern UV sensor to use. It has two modes: a UV mode that measures UVA/UVB light and lets the library convert raw counts to a UV Index, and an ambient light mode that reports lux, so one board covers both. It replaces older analog UV modules that need an ADC and careful calibration. Adafruit’s version has STEMMA QT connectors and works at 3.3V or 5V, and ESPHome has a native ltr390 component.

βœ… Pros: UV Index and lux in one board; digital I2C; ESPHome support; STEMMA QT.
❌ Cons: UV readings need a UV-transparent window outdoors (ordinary plastic and glass block much of it).
🎯 Verdict: The best way to add UV Index readings to an ESP32 weather station.
🌈 BEST SPECTRAL COLOUR SENSOR · ⭐ 4.5/5

5. Waveshare AS7341 Spectral Color Sensor

AS7341 Β· 8 visible bands plus clear, NIR and flicker detection Β· I2C Β· 3.3V/5V Β· onboard LEDs
Buy Here β†’
Waveshare AS7341 Spectral Color Sensor for ESP32

The AS7341 goes far beyond a basic RGB sensor. It splits visible light into 8 separate bands across the spectrum, plus clear and near-infrared channels and a flicker detection channel that can spot 50/60 Hz lamp flicker. That makes it useful for colour matching, checking grow-light spectra, comparing LED bulbs, simple spectroscopy experiments and sorting objects by colour. Waveshare’s board adds fill LEDs for measuring reflected colour and works at 3.3V or 5V. It is overkill for simple brightness sensing, but nothing else here gives you this much spectral detail.

βœ… Pros: Eight visible channels; flicker detection; onboard LEDs; ESPHome support.
❌ Cons: Not a calibrated lux meter; takes more code to interpret.
🎯 Verdict: The pick for colour matching, grow-light checks and spectral experiments.
πŸ‘‹ BEST FOR GESTURES AND PROXIMITY Β· ⭐ 4.4/5

6. Adafruit APDS9960 Proximity, Light, RGB and Gesture Sensor

APDS9960 Β· proximity Β· RGB and clear light Β· up/down/left/right gestures Β· I2C 0x39 Β· interrupt
Buy Here β†’
Adafruit APDS9960 Proximity, Light, RGB and Gesture Sensor for ESP32

The APDS9960 packs three sensors into one tiny chip: proximity detection out to a few centimetres, RGB and clear ambient light sensing, and gesture recognition for up, down, left and right swipes. On an ESP32 that means touchless light switches, a display that wakes when your hand approaches, or a swipe-controlled music player, while the clear channel still gives you a rough brightness level. It is not a precise lux meter, so pair it with a VEML7700 if you need accurate light readings. The Amazon listing is Adafruit’s breakout; current units ship with STEMMA QT connectors.

βœ… Pros: Gesture, proximity and colour in one; interrupt output; ESPHome support.
❌ Cons: Short proximity range; light readings are approximate, not calibrated lux.
🎯 Verdict: The fun pick for touchless controls and hand-wave wake-up displays.

βž• Also Worth Considering: Budget Picks

πŸ’° BEST BUDGET LUX SENSOR Β· ⭐ 4.3/5

7. SHILLEHTEK GY-302 BH1750 Light Sensor

The BH1750 on a GY-302 board is the classic low-cost light sensor, and the one most ESP32 tutorials use. It reports calibrated lux directly over I2C from 1 to 65,535 lux with 16-bit resolution, runs from 3V to 5V, and its ADDR pin selects 0x23 or 0x5C so two can share a bus. This SHILLEHTEK version comes with the header pre-soldered, so it drops straight into a breadboard. It saturates in direct summer sun, so choose the VEML7700 for outdoor use, but for indoor auto-dimming it is hard to beat. ESPHome supports it natively.

Buy Here β†’
β˜€οΈ BUDGET UV PICK Β· ⭐ 4.3/5

8. Waveshare LTR390-UV Ultraviolet Sensor (C)

Waveshare’s module uses the same LTR390-UV chip as the Adafruit board, offering UV and ambient light readings over I2C at 3.3V or 5V. It comes with a cable for the onboard header instead of STEMMA QT connectors and is backed by Waveshare’s wiki with Arduino, Raspberry Pi and STM32 examples. Because the sensor chip is identical, the ESPHome ltr390 component and Adafruit library work with it too. A good choice if you are building a UV station and want a second unit or a Waveshare-style cable connector.

Buy Here β†’

πŸ› οΈ Which Sensor for Which ESP32 Project?

ESP32 ProjectRecommended Sensor
Auto-dimming a display or LED stripVEML7700 or BH1750
Dusk-to-dawn porch light switchTSL2591 or VEML7700
Weather station lux and UV IndexVEML7700 + LTR390
Greenhouse and grow-light monitoringAS7341 + VEML7700
Battery sensor that wakes on light changeSparkFun VEML6030 (interrupt)
Touchless switch or gesture controlAPDS9960
Night sky and very low-light loggingTSL2591
Lowest cost indoor light readingBH1750 (GY-302)

πŸ›’ Which One Should You Buy?

β˜€οΈ

One sensor for everything

The Adafruit VEML7700 covers dark rooms to full sun.

πŸŒ™

Dark scenes and twilight

The Adafruit TSL2591 for micro-lux sensitivity.

πŸ•ΆοΈ

UV Index on a weather station

The Adafruit LTR390, or the Waveshare LTR390-UV (C).

🌈

Colour and spectrum

The Waveshare AS7341 with 8 visible bands.

πŸ‘‹

Touchless control

The Adafruit APDS9960 for gestures and proximity.

πŸ’°

Tightest budget

The BH1750 (GY-302) for indoor lux readings.

❓ Frequently Asked Questions

Can I just use a photoresistor (LDR) with the ESP32?

Yes, for simple light or dark detection. An LDR in a voltage divider on an ADC pin is cheap, but it drifts with temperature, varies between parts and the ESP32 ADC is not very linear, so you will not get accurate lux. Digital sensors like the VEML7700 or BH1750 give calibrated readings with far less effort.

Which light sensors work with ESPHome?

ESPHome has native components for the VEML7700, TSL2591, BH1750, LTR390, AS7341 and APDS9960. You add the I2C bus and the sensor block to your YAML and the readings appear in Home Assistant. The SparkFun VEML6030 needs a custom component.

Can I put several light sensors on the same I2C bus?

Yes, as long as their addresses differ. The VEML7700 (0x10), TSL2591 (0x29), LTR390 (0x53) and APDS9960 (0x39) can all share one bus. For two identical sensors, use boards with address jumpers like the BH1750 or VEML6030, or add an I2C multiplexer.

Why does my sensor read low inside an enclosure?

Any window in front of the sensor absorbs some light, and tinted, frosted or UV-blocking plastic absorbs much more. Use a clear window, mount the sensor right behind it, and calibrate by comparing against a reference meter, then apply a correction factor in code.

Is the VEML7700 or BH1750 better for outdoor use?

The VEML7700. The BH1750 maxes out around 65,000 lux, and direct summer sun can exceed 100,000 lux, so it saturates outdoors. The VEML7700 reaches roughly 120,000 lux and keeps reading accurately in bright daylight.

🏁 Final Verdict: Best Light Sensors for ESP32

The right sensor for each job:

πŸ₯‡ Best Overall: Adafruit VEML7700
Buy Here β†’
πŸŒ™ Best for Low Light: Adafruit TSL2591
Buy Here β†’
πŸ”Œ Best Qwiic Lux Sensor: SparkFun VEML6030
Buy Here β†’
πŸ•ΆοΈ Best UV Sensor: Adafruit LTR390
Buy Here β†’
🌈 Best Spectral Sensor: Waveshare AS7341
Buy Here β†’
πŸ‘‹ Best for Gestures: Adafruit APDS9960
Buy Here β†’
πŸ’° Best Budget: SHILLEHTEK BH1750
Buy Here β†’

For most ESP32 projects, the Adafruit VEML7700 is the light sensor to start with: it reads from dim rooms to full sunlight, plugs in with one cable and works in ESPHome out of the box. Choose the TSL2591 for dark scenes, add an LTR390 for UV Index, reach for the AS7341 when colour matters, and use a BH1750 when cost is the main concern. Building a full environmental station? Pair your light sensor with picks from our temperature and humidity sensors, weather station parts and PIR motion sensors guides, or browse our complete ESP32 sensors guide.

πŸ’¬ Which light sensor are you using in your ESP32 project, and what are you measuring? Share your setup in the comments below.

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.

Leave a Comment