Power surges are more likely to occur in devices that are plugged in all the time, so unplugging your modem and/or router can keep them from being damaged by random increases in electricity flowing through their wires.
Is it bad to turn off your modem?
To give a short and sweet answer, no, it's not, in any way, bad for you to turn your modems off every night. In fact, it's something that health experts recommend because leaving it turned on or activated contains more adverse effects on our health than the status and conditions of the technology around us.
Is it OK to leave WiFi router on all the time?
So, is it really ok to leave your router switched on all the time? Absolutely it is. Routers are specifically designed to run all the time. In fact, you could reduce the lifespan of the router if you're switching it on and off too frequently.