Smartphone Controlled Neopixels (LED Strip) With Blynk App Over WiFi

Introduction: Smartphone Controlled Neopixels (LED Strip) With Blynk App Over WiFi

I created this project after I was inspired by smartphone controlled neopixels in a friends house but his were shop-bought. I thought "how hard can it be to make my own, it would be much cheaper too!"

This is how.


I'm assuming you're familiar with the arduino ide environment, if not then there are many tutorials out there.


04/04/2019 - Added zeRGBa use in app.

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Gather Parts

1. NodeMCU (or another type of esp8266, but MCU will work best)

2. Jumper wires (3x male->female, 2x female->female)

3. Neopixels

4. Smartphone

Step 2: Wiring

Connect GND of Neopixels to MCU GND.

Neopixel DATA --> MCU pin D3.

Neopixel +5V --> external 5V power supply (you must connect neopixels to an external supply or they will draw to much current from the controller and fry it, plus the MCU doesn't even have a 5v pin!).

MCU GND --> power supply GND.

Power supply+ --> MCU Vin pin.

Step 3: Download Libraries

First we will need the adafruit neopixel library to control the LEDs. It can be found in the libraries manager, just search for 'adafruit neopixel' and select the one shown and install it.

Then to download the board definitions, open prefrences and paste into the 'additional board URLs' box. Then open boards manager and search for 'esp8266' it should be the first one, click on it and install it.

Step 4: Code

Create a new sketch and name it 'neopixels on esp8266 with blynk' (or something that you're going to remember). Paste in the code.

Change 'yourAuthCode' to the auth code for your project. (found in the 'nut' icon in blynk app)

Change your wifi name and password to those of your network.

Set the number of neopixels to the length of your strip.

Plug your MCU into your computer, select MCU from the board menu in the ide, select the COM port and baud rate(115200) but ignore all the rest, it should be pre-configured. Then upload!

Step 5: Blynk App

Install blynk app from app store or play store.

Once it has installed, open it and create an account.

Create a new project then drag in 2 styled buttons, 1 menu, 1 horizontal slider and 3 vertical sliders from the widget box.

Tap on the menu icon, then change the title to "Colour", tap on the box that says 'PIN' change this to virtual pin V0.

Create 9 menu items:

red, green, blue, yellow, purple, turquoise, white, off and custom. (In that order!!).

Go back then tap on one of the buttons, set it's PIN to virtual pin V2, and the 'off' label and 'on' label both to "rainbow".

Go back and click on the other button, set it's PIN to virtual pin V3, and the 'on' and 'off' labels both to "update".

Go back then click on the horizontal slider, title it "brightness", and set it's PIN to virtual pin V1, turn on 'show value' if you want and turn OFF 'send on release', the 'write interval' should be 100ms.

Go back then click on one of the vertical sliders, title it "Red", then set it's PIN to virtual pin V4, 'show value' and 'send on release' both to ON.

Do the same for the next 2 vertical sliders, but label them "Blue" and "Green", with pins virtual V5 and V6 respectively.

If you do not want to use sliders, you can use the zeRGBa tile instead. Tap on the icon, then choose pins; V4, V5, V6 for Red, Green, Blue respectively. Make sure the values are from 0 to 255.

Hold and drag a widget to move them around.

Click the play symbol in the top right-hand corner to use your app.


Make sure you connected to the same WiFi network as the MCU.

Selecting a colour from the drop down menu will set the strip that colour, use the 'brightness' slider to change the brightness then press update. Pressing the 'rainbow' button will do a rainbow pattern. If you select 'custom' then drag the 'Red', 'Green', and 'Blue' sliders to change the amounts, press update to change the colour.

Step 6: Finished!

Your project should be ready to use!

Have fun!

1 Person Made This Project!


  • Backyard Contest

    Backyard Contest
  • Silly Hats Speed Challenge

    Silly Hats Speed Challenge
  • Finish It Already Speed Challenge

    Finish It Already Speed Challenge

12 Discussions


8 weeks ago

Hey man, awesome instructable. I noticed in your code you have some stuff for getting this to work with a ws2811 strip, I was wondering if you could inform me on what else, apart from NEO_KHZXXX I'd need to change to make it work?


9 months ago

Hello brother, thank so much for sharing yout project, I´m doing everything you explain in the instructable, The rainbow effect works well, the menu with the colors work well, but the sliders don't work also the esp8266 disconnect from wifi after a short time. Could you or someone help me to solve this issue? I will be so glad


Reply 3 months ago

hi LordVallejo, I have had the same problem with a different project.
i think the problem is blynk gets bored waiting for data to come through so disconnects.
i fixed this problem by sending random data to a unused virtual pin like this:

Blynk.virtualWrite(V13, 50);

50 is just a random number, it can be anything.
put it in the end of each loop so it happens when the loop goes round.
Hope this works 4u, Have fun!!


Reply 3 months ago

Hello, thanks a lot for your replying, I truly appreciate it , I will try it, then I will tell you how was it?


Reply 9 months ago

If the sliders aren't working, it may be that you haven't chosen the correct virtual pins in the slider settings (step 5) or the numbers are wrong in the Arduino code.
The disconnection issue is odd, because I have had it as well, I believe it is just the WiFi network that you are connected to and how strong the signal is. If the signal is 2 bars or less, I find that it will be more likely to disconnect.
If not, it might be the antenna on the esp8266 is not enough, see instructables on upgrading the antenna.

Hope this helps


Reply 9 months ago

Thank you so much, but the issue is still happening. I am doing everything according to yours stpes. I don´t know what to do


6 months ago

Thanks for sharing this project. One problem: Once the rainbow mode activated no chance to go back to the other sliders and button. Only restart helps. Any recommendation?


Reply 3 months ago

hey kundeg55! i have the same problem with my neopixels.
the rainbow cycle has to finish before you can change the effect.
you can tell when it finishes because the lights stop moving.
have fun!!


Reply 5 months ago

Hello, I came up to this again. Unfortunately same thing. Cannot go out of the rainbow mode once it's started. Only hard reset on the Node MCU helps. Any idea what needs to be changed in code? Wish a Happy new Year 2020


Reply 6 months ago

I'm not really sure, I've not had that issue before. It might be that it needs to wait to finish the rainbow cycle first and then register the button press. I'll look into it more this week, thanks for the feedback!


3 months ago

Hey guys, Great project although there is one problem:
once the rainbow cycle is on you can't change the effect until the cycle is done.
but you need interrupts to do that and it's all a bit complex :D

Great first Instructable. Thanks for sharing with the community.