Main Content

WLED – Turn lights On or Off on a schedule.

WLED Logo with on off switches

If you’re new to WLED, one of the things you’re probably wondering is how you can turn the lights on at a specific time and off at a specific time. This is pretty easy, but I find this a bit confusing due to how things are named in WLED, so I wrote up a how-to.

Update: WLED now recommends using the JSON API. Use {"on":false} to turn off your lights and choose any preset to turn them on.

First, open WLED, choose an effect you like (or set up a playlist), and click on the Presets tab.

WLED Preset Screen
The screenshot is out of date, but generally the same.

Create a new preset, name it On. Uncheck Use current state and set the API command to T=1. Save the preset.

Create a new preset. I could be any preset or a playlist. You don’t have to do anything special except save a preset.

Create another new preset, name it Off. Uncheck Use current state and set the API command to {"on":false}. Save the preset.

I’m assuming these are your only two presets. If you have others, take note of the Save to ID value for both the preset you want when turned on and the off preset.

Next, click on the Config tab and go to Time & Macros then scroll down to Time-controlled presets.

WLED time controls screen

Here you can tell WLED what preset to run at what time. For example, you can stay that at 6 run preset 1. Preset 1 will turn on the lights with that specific effect. Then at 8 run preset 2 which turns off the lights. 

Keep in mind that, by default, hours are in 24 hour time so if you want to turn your lights on at 8pm, it’d be hour 20. It’s also important to ensure you have your timezone set properly at the top of the Time & Macros screen. 

You can do a lot more with presets and macros, but just learning how to turn them on and off at a specific time is a good first step.

2 Responses

  1. Brian says:

    Thanks so much!

  2. Sr says:

    Awesome, exactly what i was looking for. Couldn’t figure out myself. Thank you!

Leave a Reply