Same-day dispatch before 2 PM · Free delivery over ₹999 · GST invoices Get the appPrices incl. GST
Geekobot
Snap & SendNEWGeeko AIWhere's myOrder
Log in
Products
  • Projects
    • Component guidesHow parts work, with code you can run
    • Learning pathsFrom your first LED to your first robot
    • Workshops & eventsOnline sessions for makers and classes
    • ElectrolarkFree guided builds, simulator and certificates
    • Students & teachersStudent discount and classroom help
    • CommunityShare builds and ask other makers
    • CalculatorsOhm's law, LED resistor, 555 and 100+ more
    • Circuit builderWire parts and run the circuit, powered by Electrolark
    • Geeko AIAsk what to buy or how to wire it
    • Snap & SendPhotograph a part or list, we find it
    • Part finderAnswer a few questions, get the right part
    • Compatibility checkWill these two parts work together?
    • Compare partsSpecs side by side
    • Business & bulk ordersGST invoices, credit and volume prices
    • Request a quotationSend your list, get a quote
    • Classroom kitsPer-student kits and lab bundles
    • Gift cardsFor students, teams and events
  • Atal Tinkering Lab
BOM to cart
Geekobot

Components, kits and know-how for makers, students, engineers, labs and businesses across India.

Ask Geeko AIOrders, parts and projects, any timeEmail supportReply within 1 working dayGet the Geekobot appAdd it to your home screen, free

Follow us

Shop

  • Boards & SBCs
  • Sensors & Modules
  • IoT & Wireless
  • Drone & FPV
  • 3D Printing
  • Filaments & Resins
  • Motors & Drivers
  • Power & Batteries
  • Semiconductors
  • Passive
  • Displays & LEDs
  • Switches & Relays
  • Wires & Cables
  • Prototyping
  • Tools & Test
  • Robotics
  • STEM Kits
  • Atal Tinkering Lab
  • Mechanical Parts
  • Audio

Orders

  • Track your order
  • Help & support
  • Shipping and delivery
  • Refunds and cancellation
  • Contact us

Learn

  • Projects
  • Geeko AI project assistant
  • Learning paths
  • Guides
  • Calculators
  • Electrolark: free guided builds

Part tools

  • Part finder
  • Compare parts
  • Will it work with my board?

Institutions

  • Classroom kits
  • Atal Tinkering Lab
  • Students & teachers
  • Workshops & Events

Business

  • Business & education
  • Request a quotation
  • BOM bulk upload
  • Quick order by SKU

Company

  • About Geekobot
  • Community
  • Gift cards
  • Terms & conditions
  • Privacy policy
  • Product directory
  • Sitemap

© 2026 Geekobot, a trade name of OLatus Systems Private Limited. All rights reserved.

20, 1st Floor, Neeladri Complex, 10th Cross, Sampige Rd, 2nd Main, Malleshwaram, Bengaluru, Karnataka 560003 · GSTIN 29AACCO0462F1ZM

+91 91810 15607 · connect@geekobot.in · Monday to Saturday, 10 AM to 2 PM IST

UPI · CARDS · NETBANKING · GST INVOICES

ShopProjectsGeeko AIGuides
Compare 0 parts →
Log in

Shop by category

Shop all components
  • Boards & SBCs1,910 products
    • Alternative Single Board Computers
    • Arduino Ecosystem
    • FPGA & Logic Boards
    • Microcontroller & Wireless Boards
    View all
  • Sensors & Modules4,701 products
    • Biomedical & Heart Rate
    • Current, Voltage & Power
    • Force, Weight & Pressure
    • Gas, Weather & Environmental
    View all
  • IoT & Wireless2,314 products
    • RF Modules
    • RFID & NFC
    • Antennas & RF Accessories
    • Cameras & Smart Vision
    View all
  • Drone & FPV3,558 products
    • Flight Control & Navigation
    • FPV Video & Optics
    • Frames & Structural Parts
    • Motors & Propulsion
    View all
  • 3D Printing2,204 products
    • 3D Printers
    • 3D Scanners & Digitizers
    • Laser Engravers & Cutters
    • Material Management & Upgrades
    View all
  • Filaments & Resins1,472 products
    • Filaments
    • Photopolymer Resins
    View all
  • Motors & Drivers463 products
    • BLDC Motor Drivers
    • DC & Geared Motors
    • DC Motor Drivers
    • Linear Actuators & Solenoids
    View all
  • Power & Batteries557 products
    • Battery Holders & Connectors
    • Breadboard Power
    • Chargers & BMS
    • DC-DC Converters
    View all
  • Semiconductors295 products
    • Diodes & Rectifiers
    • Interface & RF Encoder ICs
    • Logic ICs (74xx)
    • Logic ICs (CD4000)
    View all
  • Passive67 products
    • Capacitors
    • Circuit Protection
    • Crystals & Oscillators
    • Inductors
    View all
  • Displays & LEDs572 products
    • 7-Segment & Dot Matrix
    • Addressable LEDs
    • Character LCDs
    • Graphic LCDs
    View all
  • Switches & Relays184 products
    • Keypads & Touch
    • Push Buttons & Tactile
    • Relay Modules
    • Relays
    View all
  • Wires & Cables233 products
    • Board-to-Wire Connectors
    • Crimp & Splice
    • Headers & Dupont
    • Heat Shrink & Sleeving
    View all
  • Prototyping101 products
    • Breadboards
    • Interface Modules
    • PCBs & Perfboards
    View all
  • Tools & Test717 products
    • Bench Power Supplies
    • Hand Tools
    • Measuring Tools
    • Meters & Testers
    View all
  • Robotics180 products
    • Humanoid & Legged Robots
    • Robot Chassis & Platforms
    • Robotic Arms & Grippers
    • Wheels & Casters
    View all
  • STEM Kits268 products
    • Arduino Learning Kits
    • Coding & IoT Kits
    • Early Coding (Ages 3-8)
    • Invention Kits
    View all
  • Atal Tinkering Lab196 products
    • Package 1: Electronics, Robotics, IoT and Sensors
    • Package 2: Rapid Prototyping Tools
    • Package 3: Mechanical, Electrical and Measurement Tools
    • Package 4: Power Supply, Accessories and Safety Equipment
    View all
  • Mechanical Parts212 products
    • Bearings
    • Brackets & Mounts
    • Couplers
    • Fasteners & Standoffs
    View all
  • Audio109 products
    • Amplifier Modules
    • Buzzers & Sirens
    • Speakers
    View all
  1. Home
  2. ›Guides
  3. ›Sensors
  4. ›UV Sensor Modules

Component guide · Intermediate · 4 min read

UV Sensor Modules

LTR390 (Adafruit, Waveshare, DFRobot, RAK12019), ML8511 GYML8511, Adafruit AS7331 UVA/UVB/UVC, UVM-30A, DFRobot UV Index, Sharp GA1AUV100WP and Grove Sunlight Sensor

By Geekobot Learning Team · Updated 29 Oct 2026

On this page
Short answerWhat the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) isUV sensor modules (LTR390, ML8511, AS7331, UVM-30A) pinoutWiring the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A)Example codeSetup and tuningWhat you needAlternatives and when to choose themCommon mistakesFAQsParts and next steps
Short answer

UV sensors measure ultraviolet light from the sun or UV lamps. The LTR390 is the easiest digital choice: it reads UV and ambient light over I2C and suits UV index projects. ML8511 and UVM-30A boards give an analog voltage that rises with UV. The AS7331 separates UVA, UVB and UVC, which suits UV lamp and curing checks.

Key specs at a glance

Digital
LTR390 (I2C 0x53), AS7331, GA1AUV100WP, UV index modules
Analog
ML8511, UVM-30A, ACEBOTT UV
Bands
UVA and UVB on most; UVC on AS7331 and some UV index sensors
Supply
3.3V (chips), 3.3-5V on most boards
Use
UV index, sun exposure, UV lamp checks
Window
Needs a UV-transparent cover outdoors
!Safety: High current: wires and parts get hot

This part can carry many amps. Use wire thick enough for the current, put a fuse close to the battery, check that connectors are rated for the load and give drivers and motors room to cool. A short at these currents melts wires in seconds.

Models in this guide

These are alternatives. Pick the one that fits your project; you only need one.

  • Option 1Adafruit LTR390 UV Light Sensor – STEMMA QT/Qwiic₹755
  • Option 2LTR-390UV UV & Ambient Light Sensor Module – I2C Digital Output₹489
  • Option 3Waveshare LTR390-UV Digital Ultraviolet Sensor Module – I2C Interface, 3.3V/5V₹979
  • Option 4RAKwireless RAK12019 UV Light Sensor Module Lite-On LTR-390UV-01 – I2C Interface, WisBlock Compatible₹669
  • Option 5DFRobot Gravity LTR390 UV Sensor 280–430nm I2C UART₹974
  • Option 6DFRobot Gravity UV Index Sensor (240-370nm, UVA, UVB, UVC) – I2C/UART₹1,049
01

What the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) is

UV sensor modules such as the LTR390 (I2C) and ML8511 (analog) measure ultraviolet light to estimate UV index for weather stations and sun safety projects.

For a weather station, use an LTR390 and convert its UV count to a UV index with the factor in the data sheet or library. For a simple sunlight UV meter, an ML8511 or UVM-30A on an analog pin is enough. For germicidal or curing lamps, the AS7331 can tell UVC from UVA.

Normal glass and many plastics block UV, so put the sensor behind quartz or UV-transparent acrylic, or leave it open under a small rain shield. Never look at UVC lamps.

02

UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) pinout

The pins on the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) and what each one does.

PinFunction
VIN3.3-5V
GNDGround
SDA / SCLI2C on digital modules
OUTAnalog output on ML8511 and UVM-30A
ENEnable on ML8511 boards (tie high)
PinFunction
VIN
3.3-5V
GND
Ground
SDA / SCL
I2C on digital modules
OUT
Analog output on ML8511 and UVM-30A
EN
Enable on ML8511 boards (tie high)
03

Wiring the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A)

Ordinary glass blocks most UV. Use quartz or UV-transparent plastic over the sensor.

UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) pinConnectionNote
VIN3.3VESP32 3V3
GNDGNDCommon
SDAGPIO21I2C
SCLGPIO22I2C
VIN
Connection:
3.3V
Note:
ESP32 3V3
GND
Connection:
GND
Note:
Common
SDA
Connection:
GPIO21
Note:
I2C
SCL
Connection:
GPIO22
Note:
I2C
04

Example code

Uses the Adafruit LTR390 library. Switch to LTR390_MODE_ALS to read visible light instead.

Read UV from an LTR390 (ESP32) · Arduino C++Verify & upload in Electrolark
#include <Wire.h>
#include <Adafruit_LTR390.h>

Adafruit_LTR390 ltr;

void setup() {
  Serial.begin(115200);
  Wire.begin(21, 22);
  if (!ltr.begin()) {
    Serial.println("LTR390 not found");
    while (1) delay(10);
  }
  ltr.setMode(LTR390_MODE_UVS);
  ltr.setGain(LTR390_GAIN_3);
  ltr.setResolution(LTR390_RESOLUTION_16BIT);
}

void loop() {
  if (ltr.newDataAvailable()) {
    Serial.print("UV counts: ");
    Serial.println(ltr.readUVS());
  }
  delay(500);
}
05

Setup and tuning

LTR390

connect VCC, GND, SDA and SCL; use the Adafruit LTR390 library.

ML8511

read the analog voltage and map it to UV intensity.

Window

use a UV-transparent cover; most plastics block UV.

Calibration

compare with a reference UV index for best results.

Placement

face the sky with no shade.

06

What you need

Shop this list16 of 16 found in our store · ₹14,431

  • Adafruit LTR390 UV Light Sensor – STEMMA QT/Qwiic: the part this guide coversAdafruit LTR390 UV Light Sensor – STEMMA QT/Qwiic₹755
  • LTR-390UV UV & Ambient Light Sensor Module – I2C Digital Output: another version this guide coversLTR-390UV UV & Ambient Light Sensor Module – I2C Digital Output₹489
  • Waveshare LTR390-UV Digital Ultraviolet Sensor Module – I2C Interface, 3.3V/5V: another version this guide coversWaveshare LTR390-UV Digital Ultraviolet Sensor Module – I2C Interface, 3.3V/5V₹979
  • RAKwireless RAK12019 UV Light Sensor Module Lite-On LTR-390UV-01 – I2C Interface, WisBlock Compatible: another version this guide coversRAKwireless RAK12019 UV Light Sensor Module Lite-On LTR-390UV-01 – I2C Interface, WisBlock Compatible₹669
  • DFRobot Gravity LTR390 UV Sensor 280–430nm I2C UART: another version this guide coversDFRobot Gravity LTR390 UV Sensor 280–430nm I2C UART₹974
  • DFRobot Gravity UV Index Sensor (240-370nm, UVA, UVB, UVC) – I2C/UART: another version this guide coversDFRobot Gravity UV Index Sensor (240-370nm, UVA, UVB, UVC) – I2C/UART₹1,049
  • Adafruit AS7331 UV / UVA / UVB / UVC Sensor Breakout – STEMMA QT / Qwiic: another version this guide coversAdafruit AS7331 UV / UVA / UVB / UVC Sensor Breakout – STEMMA QT / Qwiic₹3,599
  • GYML8511 Analog UV Light Sensor Module – 280-390nm Detection, 3-5V: another version this guide coversGYML8511 Analog UV Light Sensor Module – 280-390nm Detection, 3-5V₹1,939
  • UVM-30A UV Ultraviolet Ray Detection Sensor Module: another version this guide coversUVM-30A UV Ultraviolet Ray Detection Sensor Module₹935
  • Generic UV Detection Sensor Module Ultraviolet Ray Module for Arduino – DC 3.3V-5V, 0-1V Output: another version this guide coversUV Detection Sensor Module Ultraviolet Ray Module for Arduino – DC 3.3V-5V, 0-1V Output₹429
  • ACEBOTT UV Sensor Module Easy-Plug – 200-370nm, 0-5V Analog Output for ESP32/Arduino: another version this guide coversACEBOTT UV Sensor Module Easy-Plug – 200-370nm, 0-5V Analog Output for ESP32/Arduino₹589
  • Sharp Microelectronics GA1AUV100WP UV & Ambient Light Sensor, I²C Digital Output, 16-Bit ADC, 2.2~5.5V, SMD: another version this guide coversSharp Microelectronics GA1AUV100WP UV & Ambient Light Sensor, I²C Digital Output, 16-Bit ADC, 2.2~5.5V, SMD₹139
  • Seeed Studio Studio Grove Sunlight Sensor – UV/Visible/IR Light Sensor Module: another version this guide coversSeeed Studio Grove Sunlight Sensor – UV/Visible/IR Light Sensor Module₹1,309Closest match, check the specs
  • ESP32-WROOM-32 38-pin development board: for Wi-Fi logging and dashboardsESP32-WROOM-32 38-Pin Development Board₹389
  • Dupont jumper wires: for the connectionsDupont Jumper Wires (40 pcs)₹49Closest match, check the specs
  • 0.96 inch OLED display 128x64: to show readings without a computer0.96" OLED Display 128x64₹139Closest match, check the specs
07

Alternatives and when to choose them

  • ✓GUVA-S12SD UV sensor: simple analog UV.
  • ✓Ambient light and lux sensors: visible light.
  • ✓VEML7700 lux sensor: accurate lux.
08

Common mistakes to avoid

  • !Covering it with plastic.
  • !Shaded mounting.
  • !Expecting certified accuracy.
  • !Wrong analog mapping.
09

Frequently asked questions

Can the LTR390 give UV index?

Yes, it reports UV that you convert to UV index.

Why does my UV sensor read zero behind plastic?

Most plastics block UV; use quartz or UV-transparent covers.

Is ML8511 accurate?

Roughly. It shows UV levels for projects, not certified measurements.

Can I use it indoors?

Indoor UV is very low, so readings will be near zero.

Which sensor is easier to use?

The LTR390 is easier, because it uses I2C with a ready Adafruit library.

Parts for this guide

  • Adafruit LTR390 UV Light Sensor – STEMMA QT/Qwiic
    ₹755View
  • LTR-390UV UV & Ambient Light Sensor Module – I2C Digital Output
    ₹489View
  • Waveshare LTR390-UV Digital Ultraviolet Sensor Module – I2C Interface, 3.3V/5V
    ₹979View
  • RAKwireless RAK12019 UV Light Sensor Module Lite-On LTR-390UV-01 – I2C Interface, WisBlock Compatible
    ₹669View
  • DFRobot Gravity LTR390 UV Sensor 280–430nm I2C UART
    ₹974View
  • DFRobot Gravity UV Index Sensor (240-370nm, UVA, UVB, UVC) – I2C/UART
    ₹1,049View
  • Adafruit AS7331 UV / UVA / UVB / UVC Sensor Breakout – STEMMA QT / Qwiic
    ₹3,599View
  • GYML8511 Analog UV Light Sensor Module – 280-390nm Detection, 3-5V
    ₹1,939View
  • UVM-30A UV Ultraviolet Ray Detection Sensor Module
    ₹935View
  • UV Detection Sensor Module Ultraviolet Ray Module for Arduino – DC 3.3V-5V, 0-1V Output
    ₹429View
  • ACEBOTT UV Sensor Module Easy-Plug – 200-370nm, 0-5V Analog Output for ESP32/Arduino
    ₹589View
  • Sharp Microelectronics GA1AUV100WP UV & Ambient Light Sensor, I²C Digital Output, 16-Bit ADC, 2.2~5.5V, SMD
    ₹139View
  • Seeed Studio Grove Sunlight Sensor – UV/Visible/IR Light Sensor Module
    ₹1,309View
  • ESP32-WROOM-32 38-Pin Development Board
    ₹389View
  • Dupont Jumper Wires (40 pcs)
    ₹49View
  • 0.96" OLED Display 128x64
    ₹139View
Shop Ambient Light, Lux & UV Sensors

Projects that use it

Put this into practice: 26 step-by-step builds in our project library use parts from this guide.

Beginner · 1 hourUV index monitor with sunburn warningView projectBeginner · 30 minutesUV index meterView projectBeginner · 1–2 hoursWi-Fi UV index monitorView project
Browse all 26 projects

Keep learning

Component guideBeginnerGUVA-S12SD UV SensorThe GUVA-S12SD is a UV photodiode that responds to ultraviolet light from about 240 to 370 nm.3 min read · SensorsComparisonBeginnerAmbient Light SensorsAmbient light sensors such as the BH1750, TSL2591, VEML7700 and OPT3001 measure brightness in lux over I2C, so they give accurate readings that do not depend on how you wire a resistor.3 min read · SensorsComponent guideBeginnerVEML7700 Lux SensorThe VEML7700 from Vishay is a 16-bit ambient light sensor that reports lux over I2C at address 0x10.3 min read · Sensors

Sources

  • Lite-On LTR-390UV data sheet
  • ams OSRAM AS7331 data sheet
  • Adafruit LTR390 library

Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.

On this page
Short answerWhat the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A) isUV sensor modules (LTR390, ML8511, AS7331, UVM-30A) pinoutWiring the UV sensor modules (LTR390, ML8511, AS7331, UVM-30A)Example codeSetup and tuningWhat you needAlternatives and when to choose themCommon mistakesFAQsParts and next steps
Need a hand?Ask Geeko AI which part fits your project, or talk to the Geekobot team.Ask Geeko AIHelp & support

Parts for this guide8 items · ₹9,434

Adafruit LTR390 UV Light Sensor – STEMMA QT/Qwiic · DFRobot Gravity UV Index Sensor (240-370nm, UVA, UVB, UVC) – I2C/UART · Adafruit AS7331 UV / UVA / UVB / UVC Sensor Breakout – STEMMA QT / Qwiic · GYML8511 Analog UV Light Sensor Module – 280-390nm Detection, 3-5V · UVM-30A UV Ultraviolet Ray Detection Sensor Module · UV Detection Sensor Module Ultraviolet Ray Module for Arduino – DC 3.3V-5V, 0-1V Output · ACEBOTT UV Sensor Module Easy-Plug – 200-370nm, 0-5V Analog Output for ESP32/Arduino · Sharp Microelectronics GA1AUV100WP UV & Ambient Light Sensor, I²C Digital Output, 16-Bit ADC, 2.2~5.5V, SMD

Run itChange the inputs and watch the output

Raw UV counts. At gain 3 and 16 bit, UV index = counts / 2300 x ... see the datasheet formula.

Serial monitor115200 baud
UV counts: 189

A simulation of the sketch above, so you know what to expect. Real readings vary with your parts and wiring.

Ask the Community

Ask a question