Skip to content


The SparkFun Spectral UV Sensor - AS7331 (Qwiic) and Mini Spectral UV Sensor - AS7331 (Qwiic) feature the AS7331 UV sensor from ams OSRAM© which measures UV radiation on three channels: UVA (320-400nm), UVB (280-320nm), and UVC (200-280nm). Each channel on the AS7331 has an individual photodiode with built-in interference filters to ensure high sensitivity and accuracy across all three channels. The AS7331 communicates over I2C so naturally we put it on Standard (1"x1") and Mini (1"x0.5") Qwiic breakouts to integrate into our Qwiic Connect System.

This guide goes over the AS7331 UV sensor and other hardware on these Qwiic breakouts, how to assemble them into a circuit and how to use them with the SparkFun AS7331 Arduino library.

Required Materials

In order to follow along with this guide, you'll need the following materials. You'll need a microcontroller to connect the breakouts to. The development boards listed below come with Qwiic connectors for easy connection using the Qwiic system:

If your chosen microcontroller is not already Qwiic-enabled, you can add that functionality with one or more of the following items:

You will also need at least one Qwiic cable to connect your breakout to your microcontroller:

Optional Materials

If you prefer a soldered connection or want to modify the solder jumpers on these Qwiic breakouts you you may need some of the products listed below:

Suggested Reading

We designed this board for integration into SparkFun's Qwiic connect system. Click on the banner below to learn more about the SparkFun Qwiic Connect System.

Before getting started with this Hookup Guide, you may want to read through the tutorials below if you are not familiar with the concepts covered in them or want a refresher. If you are using either of the Qwiic Shields linked above, we recommend reading through their respective Hookup Guides before continuing with this tutorial: