Skip to content

Carolynxo/windows-driver-backup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Windows Factory Driver Backup Script

A PowerShell script to backup all factory drivers on a new Windows laptop before making any changes. Perfect for preserving your computer's original driver configuration for future restoration if needed.

🎯 Purpose

When you buy a new laptop, it comes with factory-tested drivers specifically configured for your hardware. This script creates a complete backup of those drivers before Windows Update or any other changes modify them. Think of it as a "snapshot" of your computer's pristine, out-of-the-box driver state.

✨ Features

  • βœ… Backs up ALL factory drivers - Graphics, WiFi, audio, touchpad, Bluetooth, webcam, chipset, and more
  • βœ… User-friendly organization - Drivers are renamed with clear, readable folder names (e.g., "01_Display_adapters_Intel")
  • βœ… Progress indicators - Visual progress bar so you know it's working, not frozen
  • βœ… Complete documentation - Generates inventory reports and restoration instructions automatically
  • βœ… Easy restoration - Simple right-click install or Device Manager integration
  • βœ… Automatic date stamping - Backups named by date (e.g., DriverBackup_Factory_20241204)

πŸ“‹ Prerequisites

  • Windows 10 or Windows 11 (64-bit)
  • Administrator privileges (required to access system drivers)
  • ~500MB-2GB free disk space (varies by number of drivers)
  • 5-10 minutes of time

⚠️ Important: When to Run This Script

Run this script IMMEDIATELY after initial Windows setup, BEFORE running Windows Update!

Correct Order:

  1. βœ… Unbox laptop and complete Windows setup
  2. βœ… Run this backup script (preserves factory state)
  3. βœ… Copy backup to external storage/cloud
  4. βœ… THEN run Windows Update

Why This Order Matters:

  • If you update Windows first, you'll backup the updated drivers, not the original factory drivers
  • Factory drivers are specifically tested by the manufacturer for your hardware
  • This gives you a true "restore point" to the out-of-box configuration

πŸš€ Quick Start Guide

Step 1: Download the Script

  1. Click on Backup-FactoryDrivers.ps1 in this repository
  2. Click the "Raw" button
  3. Press Ctrl+A to select all
  4. Press Ctrl+C to copy

Step 2: Open PowerShell as Administrator

  1. Click the Start button
  2. Type PowerShell
  3. Right-click Windows PowerShell
  4. Select "Run as administrator"
  5. Click Yes when prompted

Step 3: Run the Script

  1. Right-click in the PowerShell window to paste the script
  2. Press Enter to run
  3. Wait 4-6 minutes for completion
  4. Watch the progress bar - it will show you exactly where it's at!

Step 4: Save Your Backup

The script creates a folder like: C:\DriverBackup_Factory_20241204

CRITICAL: Copy this entire folder to:

  • βœ… External USB drive (recommended)
  • βœ… Cloud storage (Google Drive, OneDrive, Dropbox)
  • βœ… Both for maximum safety!

πŸ“ What Gets Backed Up

The script backs up ALL hardware drivers including:

Driver Type Examples
Graphics Intel/AMD/NVIDIA display drivers
Network WiFi adapters, Ethernet, Bluetooth
Audio Sound cards, speakers, microphone
Input Devices Touchpad, keyboard, touchscreen
Storage SSD/HDD controllers
Chipset System management, USB controllers
Camera Webcam drivers
Sensors Accelerometer, ambient light sensor
Power Battery management

Typically 20-50+ driver packages depending on your hardware.

πŸ“‚ Backup Folder Structure

After running the script, you'll have an organized backup like this:

DriverBackup_Factory_20241204\
β”‚
β”œβ”€β”€ πŸ“„ QUICK_REFERENCE.txt          (Start here - lists all your drivers)
β”œβ”€β”€ πŸ“„ Driver_Inventory_Report.txt  (Detailed searchable list)
β”œβ”€β”€ πŸ“„ README_RESTORE_INSTRUCTIONS.txt (How to restore drivers)
β”œβ”€β”€ πŸ“„ System_Information.txt       (Your computer specs)
β”‚
β”œβ”€β”€ πŸ“ 01_Display_adapters_Intel    (Graphics driver)
β”œβ”€β”€ πŸ“ 02_Network_adapters_Realtek  (WiFi driver)
β”œβ”€β”€ πŸ“ 03_Sound_video_game_controllers_Realtek (Audio)
β”œβ”€β”€ πŸ“ 04_HIDClass_Synaptics        (Touchpad)
β”œβ”€β”€ πŸ“ 05_Bluetooth_Intel
└── ... (all other drivers with clear names)

No more cryptic "oem45.inf" files - everything is clearly labeled!

πŸ”„ How to Restore Drivers

Method 1: Right-Click Install (Easiest)

  1. Open the driver folder you need (e.g., 02_Network_adapters_Realtek)
  2. Find the .inf file
  3. Right-click it and select "Install"
  4. Follow any prompts

Method 2: Device Manager

  1. Right-click Start β†’ Device Manager
  2. Find the device with issues
  3. Right-click it β†’ "Update driver"
  4. Choose "Browse my computer for drivers"
  5. Navigate to the specific driver folder
  6. Click Next

Method 3: "Have Disk" Method

  1. Open Device Manager
  2. Right-click device β†’ "Update driver"
  3. "Browse my computer" β†’ "Let me pick from a list"
  4. Click "Have Disk"
  5. Browse to the driver folder and select the .inf file

Full restoration instructions are included in the backup folder!

πŸ› οΈ Troubleshooting

"Script must be run as Administrator"

  • You didn't open PowerShell as Admin
  • Close PowerShell and reopen with "Run as administrator"

"Execution policy" error

Run this command in PowerShell (Admin) first:

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser

Then run the backup script again.

Script seems frozen

  • Check for the animated dots or progress bar - if you see them, it's working!
  • Phase 1 (Export) takes 3-5 minutes and is the slowest part
  • Be patient and let it complete

Not all drivers backed up

  • Some drivers are built into Windows and don't get exported (this is normal)
  • The script only backs up "third-party" hardware drivers
  • This is exactly what you want - built-in Windows drivers reinstall automatically

πŸ’Ύ Storage Recommendations

Backup Size:

  • Typically 500MB - 2GB depending on your laptop
  • Make sure you have enough space on your USB drive or cloud storage

Where to Store:

  1. Primary backup: External USB drive (keep it safe!)
  2. Secondary backup: Cloud storage (Google Drive, OneDrive, Dropbox)
  3. Why both? USB can fail, cloud accounts can be lost - redundancy is key!

❓ FAQ

Q: Will this work on any Windows laptop?

A: Yes! Works on any Windows 10 or 11 laptop (64-bit). The script adapts to whatever drivers your specific hardware has.

Q: Can I run this on a laptop I've already been using?

A: Yes, but you'll backup the current drivers, not the original factory drivers. Still useful, but not the same as preserving the factory state.

Q: Will this backup my files, programs, or settings?

A: No, this only backs up hardware drivers. For a complete system backup, use Windows System Image or third-party backup software.

Q: Do I need to keep updating this backup?

A: No! This is a one-time backup of your factory drivers. If you intentionally update drivers later, you might want to create a new backup, but the factory backup remains your "return to stock" option.

Q: Can I share my driver backup with someone who has the same laptop model?

A: Technically yes, but it's better for each person to run the script on their own laptop. Driver packages can be large, and even the same model might have slightly different hardware revisions.

Q: How do I know which driver I need from my backup?

A: Open QUICK_REFERENCE.txt or Driver_Inventory_Report.txt and search (Ctrl+F) for keywords like "wifi", "audio", "graphics", "touchpad", etc. The folders are named clearly so you can also just browse them.

Remember: Backup your backup! Store it in multiple places - you never know when you'll need it.

Pro tip: Take a photo of your laptop's model number and serial number sticker and store it with your backup. Helpful for future reference!

About

PowerShell script to backup factory Windows drivers with user-friendly organization and progress indicators

Topics

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors