How to Back Up and Transfer Wi-Fi Passwords From a Windows PC to Another

Backup And Restore Wi Fi Passwords Windows

Most PCs connect to hundreds of Wi-Fi networks throughout their lifespan. Unfortunately, those saved Wi-Fi credentials may easily get lost if you don’t regularly back them up. We discuss it more in this tutorial and demonstrate how to easily transfer Wi-Fi passwords from one Windows PC to the next.

Can’t view a PDF in Windows? It might have a password. Learn how to remove a password from a PDF.

Why Back Up Wi-Fi Passwords

Backing up Wi-Fi passwords allows you to:

  • share them with other devices, especially your own. For instance, it’s much easier to batch-transfer your saved Wi-Fi passwords to a new PC instead of reentering them.
  • restore them after performing a clean Windows install.
  • share them with friends and family so that they can also connect to your Wi-Fi network.

1. Use a Microsoft Account to Sync Wi-Fi Passwords

Windows 11/10 allows users to sync their settings over the cloud, including saved Wi-Fi passwords, alongside accessibility and some other Windows settings. To do this, you need nothing more than a Microsoft account.

  1. Open the Settings app on your computer via the Start menu or by pressing Win + I.
  2. Navigate to “Accounts -> Windows backup.”
Windows Settings Accoounts Backup
  1. Enable the “Remember my preferences” option and click the arrow icon next to it to expand its settings. Choose what you want to sync with your Microsoft account. For example, syncing “Passwords” and “Other Windows Settings” will keep your Wi-Fi passwords in sync across Windows devices where you’re signed in with your Microsoft account.
Windows Backup Enabling Remembering Prefrences
  1. If you don’t have a Microsoft account, this won’t work. Fix it by navigating to “Accounts -> Your info.”
Windows Settings Accounts Your Info
  1. You’ll find that your account is labeled as a “Local account,” with an option to “Sign in with a Microsoft Account instead.” Click on it and sign in to sync your settings with this Microsoft account. If you don’t have a Microsoft account, you can create one from this screen.
Sign In To Microsoft Account Instead
  1. To find the same settings on Windows 10, open the Settings app by pressing Win + I and open “Sync your settings” using search, then choose to sync Passwords, Windows Settings, and everything else.

2. Take Advantage of CMD to Back Up Wi-Fi Passwords

The previous method may not be the most suitable for all users, as some of them may be using Windows without a Microsoft Account. They may even want to share Wi-Fi passwords with someone else. In this case, you can back up all your saved Wi-Fi passwords in the blink of an eye using CMD (or Command Prompt).

  1. Create a new folder with your name of cohice – “Wi-Fi Passwords,” for example. We are exporting the passwords to this folder and will import them later.
Create A Folder Wi Fi Passwords 1
  1. Launch the Command Prompt. One way to do this is to search for it via Windows search then choose “Run as administrator.” 
Run Cmd
  1. Copy the following command into the window that appears:
netsh wlan export profile key=clear folder=
  1. Don’t rush to press Enter, as we need to add the path to the folder we created earlier. To quickly grab the folder’s path, hold Shift and right-click the path, then select “Copy as path.”
Copy Folder Path
  1. Go back to Command Prompt and paste the path you’ve copied right after the “=” in the command. The easiest way to do this is to hit Ctrl + V to paste it directly.
netsh wlan export profile key=clear folder="C:\Users\YourUserName\Desktop\Wi-Fi Passwords"
Command Prompt Backup Wi Fi Passwords
  1. Open the folder once more to see all the saved Wi-Fi networks listed as XML files.
Wi Fi Passwords As Xml Files
  1. You now have a backup of every Wi-Fi network you’ve connected to. You can open any XML file using Notepad or your browser and see the information. The passwords are enclosed within the <keyMaterial> tags.
Wi Fi Password In Xml File

Good to know: switching from macOS to Microsoft’s operating system? Here are some essential tips for users coming to Windows.

Restore Wi-Fi Passwords on Another Device

When you switch to a new PC or do a fresh install of Windows, you can quickly restore the Wi-Fi passwords using the folder we created earlier. The good thing is that you can restore only the needed Wi-Fi passwords instead of all of them.

  1. Copy or move the folder you created earlier (Wi-Fi Passwords) to the new PC using a USB stick or cloud drive.
  2. Open Command Prompt and enter the following command:
netsh wlan add profile filename="PATH" user=current
  1. Copy the path of the XML file associated with the Wi-Fi network you want to restore, as shown above.
  1. Navigate back to the Command Prompt and replace “PATH” with the copied path. The command should look something like this:
netsh wlan add profile filename="C:\Users\MA\Desktop\Wi-Fi Passwords\Wi-Fi-Dexters-WiFi.xml" user=current
Command Prompt Restore Wi Fi
  1. You’ll have to do the same for every Wi-Fi password you want to retrieve on your new PC. Also, you can share this folder with anyone to restore those networks in the same way so that their device automatically connects when they are near any of the listed Wi-Fi networks.

3. Use QR Codes to Share Wi-Fi Passwords

This approach may differ from the common ways we back up and transfer Wi-Fi passwords from one Windows device to another, but it’s still helpful (and maybe cool) for some users with specific setups.

You can easily create a QR code that, when scanned, connects the device seamlessly to a specific Wi-Fi network.

  1. Launch your web browser and navigate to on your Windows PC or a smartphone.
  2. Enter the network name and password into the SSID and Key fields, respectively, then click the “Generate” button. You may also set it up for a hidden Wi-Fi network.
Create Qr Code For Wifi Qufi

The QR code will instantly appear. You can share it or even print it for easier use. Later, you can scan it using any device, including Windows devices, as they can scan QR codes too.

Qr Code Qifi For Wifi Password 1

Note: if you want to be reminded of a Wi-Fi network password, you don’t need to go through the backup and restore process. Instead, view your saved Wi-Fi passwords for quick recall.

Frequently Asked Questions

Is it safe to share Wi-Fi passwords after backing them up?

Yes, it’s safe to share them across your devices. However, be cautious when sharing Wi-Fi passwords with other people, as their devices can9 connect to your network afterward. If at some point you don’t want to allow them to connect anymore, you’ll need to kick off the unwanted connection, then change the password.

Can I share my PC's Internet connection without sharing my Wi-Fi password?

Yes, you can create a mobile hotspot that lets your PC share its own connection using a custom network name and password. To set that up, go to “Settings -> Network and Internet,” and activate the “Mobile Hotspot” option. Tap the arrow next to the activation toggle to reveal the full settings. Choose the name and password of the initiated network, then share this new password with the person trying to connect to your network.

How can I remove specific Wi-Fi networks from my Windows PC?

Navigate to “Settings -> Network & Internet -> Wi-Fi” to expand the settings. Click on “Manage known networks” and hit the “Forget” button next to any network you want to remove. Furthermore, from the “Network & Internet” settings page, you can go to “Advanced network settings -> Network reset” if you want to wipe every saved network.

Image credit: Unsplash. All screenshots by Mustafa Ashour.

Mustafa Ashour
Mustafa Ashour

Mustafa is a tech content writer who's a geek at heart. His passion lies in writing about technology, especially software-related topics. He's also interested in digital marketing, business development, and entrepreneurship. He holds a Bachelor's degree in Accounting and Finance.

Subscribe to our newsletter!

Our latest tutorials delivered straight to your inbox