How to backup and Restore Device Drivers using command Prompt

These days, Windows 10 operating system comes pre-loaded with almost all essential system drivers. Even if it lacks a few, one can easily get them visiting the manufacturer’s website. However, what if you want to backup certain drivers that have become obsolete and are no longer available anywhere online. Well, in this post, we discuss an easy approach to backup device drivers using Command Prompt

Backing up device drivers becomes a necessity if their manufacturers have already stopped offering new updates. This is why Microsoft provides a useful command that can help to back up all installed drivers on the computer. Apart from backing up these drivers, we will also look at methods to restore them whenever required. 

How to Backup device drivers in Windows 10

Here’s how to use Command Prompt to create a backup of all system drivers –

Step-1: Before proceeding ahead, create a folder where you want to store this backup. We recommend using an external hard disk if you are planning to clean install Windows 10. 

  • Click the File Explorer icon and this will start under the Quick Access.
  • Navigate to This PC > Disk Drive (C or D) whichever you prefer. Make a right-click anywhere on the blank area and choose to New > Folder.
  • Rename this folder to something “DriverBackup“.

Create New folder

Step-2: Launch Command Prompt having Administrative privileges and run the following DISM code.

  • Do press the Enter key to start execution –

DISM /online /export-driver /destination:D:\DriverBackup

backup and Restore Device Drivers using command prompt

  • The system immediately starts backing up the drivers available at C:\Windows\System32\DriverStore.
  • While doing so, DISM will create a backup of only .inf drivers leaving aside the drivers with .exe or .msi extensions. 

Drivers backup folder

Note: In the above path D:\DriverBackup implies the location where you want to back up the device drivers. In case you have created this folder in some other disk drives, replace D:\ with the appropriate ones.

How to Restore device drivers in Windows 10

Just like creating drivers backup, restoring them is pretty simple and easy to perform. To do so, follow these steps –

Method 1: Using Command Prompt

  • Press WinKey + R to launch the Run dialog.
  • Type “cmd” in the text field and press Enter.
  • When the UAC window comes into the display, hit Yes.
  • On the elevated prompt, copy/paste the below code and hit Enter

 DISM /online /Add-Driver /Driver:D:\DriverBackup /Recurse

  • The system should retrieve back all of the backed device drivers at D:\DriverBackup.

There is a possibility that the above code won’t work and return an error message which reads the following –

error: 50 “This command can only be used with an Offline image.”

If that’s the case, manually restore drivers using the Device Manager.

Method 2: Via Device Manager

In general, performing a clean installation of Windows 10 will reinstall almost all essential drivers leaving aside a few ones. You may install the remaining ones following the below guideline –

  • Make a right-click on the Windows icon and select Device Manager
  • Now, expand each one of the device categories and see whether it contains any driver or not. Windows 10 OS usually highlights such sections by naming them an unknown device. 
  • If you find such a result, do the right-click, and choose to Update Driver option.
  • Subsequently, click “Browse my computer for driver software” option.

backup and Restore Device Drivers

  • Browse to the driver’s backup folder, click the sub-folders there, and press the Next button.
  • Wait for the driver to install correctly. Repeat this for all those sections that contain an unknown device.
  • Lastly, close Device Manager and Restart Windows so that installed drivers start working from the next logon.

If you find the above procedure tedious, read how to install Device Drivers via Optional Updates. However, doing so you simply can’t get back the network adapter or older drivers that are no longer supported by Windows 10.