Is my ESP32 rebooting itself? it disconnect from wifi few times a day

The documentation Spiro hinted at is from esphome, so the example timing settings would go in the yaml for the esp. But the point was NOT to use the settings. If you read both the docs and this comment below, it basically says the same as you: Wifi and bluetooth are a difficult combination on an esp.

That is because they do time sharing on the same radio. So changing timings on the bluetooth communication will affect wifi and vice versa. That is why the quoted documentation advises to go for an Ethernet ESP if you can. The timings settings shown would hurt your cause because they are for ethernet, not for wifi. For wifi it says to not use timings other than the default.

Your post shows a lot of frustration. Please try not direct the frustration of not getting the ESP to work at the people trying to help you. We get the frustration, but we are not the cause. Plus ESP’s are technical stuff. ESPHome makes it as easy as possible to write firmware, but you are programming nontheless, and that comes with its own challenges. Usually things work quite well, but there are many things that can go wrong too.

What you (and the OP too) failed to do was provide us with the yaml you use for the esp. As said, without it we are only guessing. So please post your yaml.