esp8266 doesn't reconnect to wifi network automatically after the connection is broken

Hello ,
I’m new to the blynk environment, and I have until just work with the esp8266 and I have an issue with it. I have made a lamp that turn on and off through blynk on my cell phone. The problem lies when the esp8266 connection with my router is broken the esp8266 doesn’t reconnect by itself and therefore I have to turn off and then on the esp8266. Does somebody know where the problem could be?

Hello, Please post your code, it may help.

here it is. it is the basic esp8266 standalone code

char auth[] = “YourAuthToken”;

void setup()
{
Serial.begin(9600);
Blynk.begin(auth, “ssid”, “pass”);
}

void loop()
{
Blynk.run();
}

Could you please add debug, maybe it will clarify what exactly is wrong.

i added debug but it says everything it alright

All is ok? So how do you know that problem in ESP and not in app or server?

well i suppose it líes in the esp cause i tried to do the exactamente same project but with ab arduino mega + ethernet shield and didnt have any conncetion issues