Your Windows 10 computer must run Windows 10 build 14942 or higher build versions to use this feature.
1. Automatically turn on Wifi after a few hours
This is the fastest solution to turn off and reopen Wifi on Windows 10 computers.
First click the Wifi icon in the Taskbar system tray to see all available Wifi connections and check which network connection your computer is connected to.
If the Wifi icon is not displayed on the Taskbar system tray, you can refer to the steps to restore the Wifi icon in the Taskbar here.
Next click on the Wifi icon box to turn off Wifi and to open the Flyout Menu.
At Turn Wi-Fi back on, you can choose the option of Print 1 hour, Un 4 hours or Print 1 Day. Depending on the option you choose, Windows 10 will automatically turn on Wifi again after 1 hour, 4 hours or 1 day.
2. Through Settings settings
First open the Settings app on your Windows 10 computer, then on the Settings window, find and click Network & Internet icon.
Click on Wifi to see Wifi settings.
In the Wifi section, turn off Wifi to see the option Turn Wi-Fi back on.
Here you select the option Print 1 hour, Print 4 hours, or Print 1 day from the dropdown Menu to automatically turn on Wifi after 1 hour, 4 hours or 1 day.
Refer to some of the following articles: