To join the CheerLights project, you need to build a display of the latest CheerLights color. The display can be a physical set of multicolored lights or a virtual display like a web page, widget, or app. In all cases, the displays read the latest CheerLights color using the CheerLights API.

CheerLights GitHub

Check out GitHub for our latest examples using Arduino and different types of lighting displays and libraries.

ThingSpeak Arduino / Particle Library

ThingSpeak has an official library for Arduino and Particle / Spark devices. Once you have installed the library, you will have access to a CheerLights example that will run on Arduino and Particle devices.

Library Installation

Arduino IDE

In the Arduino IDE, choose Sketch/Include Library/Manage Libraries. Click the ThingSpeak Library from the list, and click the Install button.

Particle / Spark IDE

In the Spark Web IDE, click the libraries tab, find “ThingSpeak”, and choose “Include in App”.


To get the latest color name at the command line, type:


CheerLights Command Line CURL

Web Widgets

A Web widget is some HTML, JavaScript, and CSS to display the latest CheerLights color on your website, WordPress blog, or Tumblr site. This is an easy way for web developers to join the CheerLights project. To build a widget, you need to make an AJAX call to the CheerLights API, parse the response for the latest color, and set the color of an object with the color. field2 contains the HTML HEX color value of the latest color.


Place code like this in the head of an HTML document to read the latest color from CheerLights and set the background color of the web page to that color.

$(document).ready(function() {
// get cheerlights color from field2 with a webservice call
$.getJSON('', function(data) {
// if the field2 has data, update background color of the page
if (data.field2) {
$("body").css("background-color", data.field2);


Using MATLAB you can read in the latest color or do analysis on CheerLights to discover popular colors and how long colors get displayed during the day. To use CheerLights with MATLAB, install the ThingSpeak Support Toolbox. Once you install the toolbox, you will have access to the “thingSpeakRead” function. This is what you will use to read the latest colors into MATLAB.

latestCheer = thingSpeakRead(1417, 'outputFormat', 'table');
currentColor = latestCheer.LastCheerLightsCommand

CheerLights MATLAB ThingSpeak