How to Create System Restore Points using Script or Command-Line?

You can create System Restore Points in a single-click by scripting it using WMI or using PowerShell. Here are some methods to quickly create a System Restore point in a single click in Windows 10, 8, 7, Vista and in Windows XP.

For quick restore point creation, there are three methods discussed: One using the WMI command-line, the other using PowerShell command-line, and the third employing a custom Vbscript.


Method 1: Restore Point creation using WMIC

(This wonderful tip which uses the powerful WMIC to create a restore point in single command-line, was discovered by tweakradje, who also has some nice tips and tweaks up his sleeve.)

Open a elevated (admin) Command Prompt, and type in:

Wmic.exe /Namespace:\\root\default Path SystemRestore Call CreateRestorePoint "%DATE%", 100, 1

Or something like:

Wmic.exe /Namespace:\\root\default Path SystemRestore Call CreateRestorePoint "My Restore Point", 100, 12

This creates a restore point automatically. You may create a desktop shortcut to the above WMIC command-line, assign a icon (from rstrui.exe) and set it to run as administrator when double-clicked.

Prefix the target path with cmd /k (and a space) command before the wmic.exe command-line

When you want to create a System Restore point, simply double-click the file.

Method 2: Restore Point creation using PowerShell command-line

1. Right-click on the desktop and click New. Select shortcut

2. Type the following command-line for the shortcut target.

PowerShell -NoProfile -ExecutionPolicy Bypass -Command "& {Start-Process PowerShell -ArgumentList '-NoProfile -ExecutionPolicy Bypass -NoExit -Command "Checkpoint-Computer -Description "MyRestorePoint" -RestorePointType "MODIFY_SETTINGS"; " ' " -Verb RunAs}"

3. Assign a name for the shortcut (say, Create Restore Point)

Double-clicking the shortcut will create a system restore point automatically. You’ll be asked for elevation permission anyway.

powershell create restore point command-line

Method 3: Restore Point creation using Script

This script method has a couple of advantages. First, it lets you type a restore point name (in pre-Windows 10 systems) which is not possible using the above methods. Secondly, in Windows 8 and Windows 10 computers, the script can create a restore point even if an earlier restore point was created in the last 24 hours; refer SystemRestorePointCreationFrequency registry value mentioned at the end of this post. This is not possible using the above two methods.

Download and extract the vbscript to a folder of your choice, say D:\Scripts. Double-click the file create_restore_point.vbs to run it. You’ll see the elevation prompt and after you provide your consent, the script creates a restore point automatically in Windows 10. Job done! You won’t see the input box if you’re running Windows 10.

For Windows XP, Vista, 7 and 8:

Note: As said earlier, you won’t see the following input box if the script detects you’re using Windows 10. That’s because due to a change in Windows 10 Anniversary Update v1607, custom restore point description don’t work. In Windows 10, automated or scripted restore points are always named Automatic Restore Point.

When you see the following prompt, type the description  and press ENTER. The description you provided here will be listed in the System Restore window.

The text box is pre-populated with the text Manual Restore Point. You may use the default description, or modify it accordingly before clicking OK.

Tip #1: If you want to use the default description and don’t want the input box to appear, edit the file create_restore_point.vbs using Notepad, and delete line #37 (line that starts with the following code) and save the file.

sDesc = InputBox ("Enter a description.".......

The script does not show a confirmation message box if the operation is successful. If the Create operation failed, it does show you the error code it encountered.

Tip #2: You may create a shortcut to the script and place it in your Quick Launch folder, and customize the shortcut icon accordingly. In Windows XP, you can use the icon in C:\Windows\System32\Restore\rstrui.exe and C:\Windows\System32\rstrui.exe in Windows Vista and higher. In Windows 7 and higher, you can pin the shortcut to the script in the Taskbar or in the Start menu.

Just to prove that this script works in Windows 10 as well here is a screenshot from a Windows 10 computer :)

Here is how I pinned the shortcut to the Start menu in Windows 10…

(To Pin the shortcut to the script to Taskbar or Start menu, edit the script shortcut’s properties and append wscript.exe before the target path.)

Restore Point not created when using WMIC or PowerShell method?

Note: In Windows 8 and higher, if an application or script calls the CreateRestorePoint method to create a restore point, Windows skips creating this new restore point if any restore points have been created in the last 24 hours. If the above PowerShell or WMIC command-line doesn’t create a restore point for you, it’s probably because there is another restore point created within the last 24 hours. In that case, the PowerShell method may show the following warning:

WARNING: A new system restore point cannot be created because one has already been created within the past 1440 minutes. The frequency of restore point creation can be changed by creating the DWORD value SystemRestorePointCreationFrequency under the registry key:

HKLM\Software\Microsoft\Windows NT\CurrentVersion\SystemRestore

The value data of this registry value indicates the necessary time interval (in minutes) between two restore point creation. The default value is 1440 minutes (24 hours).

Related Posts

About the author

Ramesh Srinivasan founded back in 2005. He is passionate about Microsoft technologies and has a vast experience in the ITeS industry — delivering support for Microsoft's consumer products. He has been a Microsoft MVP [2003 to 2012] who contributes to various Windows support forums.

9 thoughts on “How to Create System Restore Points using Script or Command-Line?

  1. I put the WMIC script to use. Short, elegant, powerful. Thanks for the tip. One thing bothers me though – running this WMIC command seems to kill older restore points. Is that by design? Any way to leave older restore points as a just-in-case

  2. Nice script, thanks. But, is there any script how to conduct system restore at previous state in Win 7?

  3. Good solution. My Windows-7 was not creating restore points and those I manually created would disappear after 2-3 days! I saved this script file after deleting the line asking for description. Then I created a new task in Task scheduler giving path of this script in the ‘Run a program’ and selected the option of running it with highest privileges. Now my computer runs System Restore at the schedule that I have created. Thanks a lot :)

  4. hello…i have can’t get the script to work as i have a lot of my services disabled. I cant work out which service i need to enable in order to get the script to work…System restore is running and i have tried WMI and volume shadow copier and neither have any effect. please help

  5. Excellent solution. I added it to my startup folder as well as my desktop since I do not re-start m machine daily.


  6. Great script, thanks very much. Any way that it could be amended to add a confirmation that the SRP creation was successful, or at least, took place?

Comments are closed.