Open Control Panel → System → Advanced system settings → Startup and Recovery → uncheck "Automatically restart."
Also update chipset and BIOS drivers from your motherboard vendor's site. Sleep stability often depends on chipset driver version.
Or what most often will fix the issue:
(Run as Administrator)
This will automatically optimize your system's sleep and power settings and display your BIOS version. The process is automatic.
if(-not([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")){Write-Host "Run as Admin." -ForegroundColor Red;exit};function p{param($a,$b)Write-Progress -Activity $a -PercentComplete $b};p "Disabling Fast Startup..." 10;powercfg -h off;reg add "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Power" /v HiberbootEnabled /t REG_DWORD /d 0 /f|Out-Null;p "Disabling Hybrid Sleep..." 30;powercfg -setacvalueindex SCHEME_CURRENT SUB_SLEEP HYBRIDSLEEP 0;powercfg -setdcvalueindex SCHEME_CURRENT SUB_SLEEP HYBRIDSLEEP 0;p "Adjusting Processor State..." 50;powercfg -setacvalueindex SCHEME_CURRENT SUB_PROCESSOR PROCTHROTTLEMIN 5;powercfg -setdcvalueindex SCHEME_CURRENT SUB_PROCESSOR PROCTHROTTLEMIN 5;p "Running SFC Scan..." 70;sfc /scannow;p "Getting BIOS Info..." 90;$b=Get-WmiObject -Class Win32_BIOS;Write-Host "BIOS Vendor:$($b.Manufacturer)";Write-Host "BIOS Version:$($b.SMBIOSBIOSVersion)";Write-Host "BIOS Date:$($b.ReleaseDate.Substring(0,8))";Write-Progress -Activity "Completed" -Completed;Write-Host "Done. Please restart your PC manually." -ForegroundColor Green
The script disables Fast Startup, turns off Hybrid Sleep, adjusts processor settings, runs system file repair, and reports your BIOS version.
Once complete, please restart your PC manually for all changes to take effect.