Biomechanist and bestselling author Katy Bowman utilizes a basic electrical timer to do this automatically. You simply install it in the socket where you plug your router in, and just set it to turn the power off during your preferred sleepy time. You can find more info about these easy-to-use electrical timers in the Sleep Smarter bonus resource guide as well.