When you upgrade from a previous version of Windows 10 to the latest version or when you upgrade from Windows 7/8 to Windows 10, Windows 10 keeps a copy of the previous version of Windows so that users can roll back to the previous version if they encounter issues with the newest version.
With default settings, Windows 10 allows you to go back to the previous version of Windows in the first 10 days (the roll back period was reduced from 30 days to 10 with Anniversary Update). That is, users have up to 10 days of period to go back to the previous version. In this period, one can navigate to Settings app > Update & security > Recovery > Go back to the previous version of Windows to begin restoring the previous version of Windows.
Windows 10 automatically deletes files of the previous version after 10 days, and you won’t be able to roll back after that. In fact, the Go back to previous version of Windows/Windows 10 doesn’t appear in the Settings > Update & security > Recovery page post the 10 days roll back period.
For most users, a 10-day window is more than enough. However, there are users who would like to go back to the previous version post the 10-day time period. This is especially true for users who use their PCs once in a while or if the particular PC is not their daily driver.
Although there is no option under Settings and Control Panel to change the default 10-day roll back period, there is a way out there to increase or reduce the default 10-day roll back period.
Increase roll back period from 10 days to up to 60 days
Here is how to change the default 10-day roll back period in Windows 10.
Step 1: Open the Command Prompt as administrator. To do that, type CMD in Start/taskbar search, right-click on the search result and then click Run as administrator option.
Click Yes button if and when you get the User Account Control prompt.
Step 2: At the Command Prompt window, copy and paste the following command and then hit the Enter key.
DISM /Online /Set-OSUninstallWindow /Value:30
In the above command, replace “30” with a number that you would like to keep the files of previous version of Windows. The maximum roll back period that you can currently set is 60 days.
NOTE: If you get “Error:3. The system cannot find the path specified” error, it is likely because there is no previous version of Windows files on your PC. Run the command again after upgrading to a newer version of Windows 10. We got the error when we ran the command on two PCs that didn’t have files of previous version of Windows. However, the error didn’t appear when we ran the command on a PC which was upgraded to the newest version of Windows 10 just two days ago. So, it appears that we need to run the command before the roll back period expires.
Please note the files of previous version of Windows take significant amount of disk space. To manually delete them, learn how to delete previous Windows files in Windows 10 guide.