It works fine without define TAMPLATE_ID and DEVICE_NAME

I was working on the old Blynk version, now when I moved to new one, the web app says we must define BLYNK_TEMPLATE_ID and BLYNK_DEVICE_NAME in the code.
I just defined the BLYNK_AUTH_TOKEN and it works fine
So … why should we define them ? is there any problem without these defines ?

It depends how you’re doing your Blynk connection.

If you just do Blynk.begin(auth); then Blynk Libraries with version greater than 0.6.1 will try to connect to the Blynk Legacy servers (
Later versions of the Blynk library (and you should currently be using 1.0.1 with Blynk I0T) will look at the first two lines of code in the sketch. If the library sees a Template ID in there then it will know that it has to connect to the Blynk IoT cloud servers ( instead.

If you manually specify the IoT cloud server in your Blynk connection code then you can work around this behaviour, and I believe that you can even force the legacy library to connect with the IoT cloud severs (but this isn’t a good idea!).

There’s also some info in this topic…


thank you for your reply
that’s how i connect to blynk:
Blynk.config(AUTH, "", 8080);

it works fine …so why should i define them ?

It’s your choice. If you want to specify the server in your connection string then go with your approach.