Every PC user faces the situation of needing to connect a new device to a wireless network but having forgotten or lost the password. Fortunately, the operating system Windows 10 Stores profiles of all previously connected networks in its registry. This means that if your computer has successfully connected to the router at least once, the access key hasn't disappeared; it's simply hidden from the average user.
There are several ways to extract this information: through the graphical settings interface or using a more powerful system administration tool—the command line. The second option often seems complicated to beginners, but it is the most versatile and fastest. In this article, we'll take a detailed look. How to find the Wi-Fi password on a Windows 10 computer using cmd, without resorting to third-party software.
Using the console allows you to access hidden system settings that aren't visible in standard menus. This is especially useful when the graphical shell interface isn't working properly or when you need to quickly copy input data to another device. We'll walk you through the steps step by step so you can restore access to your network in just a few minutes.
⚠️ Attention: All the steps described below are intended solely for recovering passwords for your personal networks or networks whose administrator has given you explicit permission to manage profiles. Hacking other people's Wi-Fi networks is illegal.
Why Use Command Prompt Instead of Windows Settings
Many users are accustomed to searching for passwords in the graphical interface, navigating through long menu chains in "Settings" → "Network & Internet." However, this method isn't always convenient, especially if you need to find the key for the network the computer is currently connected to, or for a network that was active in the past but is currently out of reach.
Command line (cmd) provides direct access to the wireless network profile database. This tool is built into the system by default, requires no additional drivers, and even works in safe mode. Getting results through the console is significantly faster than manually switching between settings windows.
Furthermore, the CMD method often comes in handy when the Windows graphical shell freezes or malfunctions. This low-level approach gives the administrator complete control over network configurations. Not only can you view symbols, but you can also manage profiles: delete old ones, rename them, or export them.
Getting Started: Launching the Console with Administrator Privileges
Before entering commands, you must have the appropriate access rights. Windows 10 strictly enforces security, so standard user rights won't allow you to view saved encryption keys. You'll need to run the console as an administrator.
There are several ways to do this. The fastest is to press a key combination. Win + X and select "Windows PowerShell (Administrator)" or "Command Prompt (Administrator)" from the menu that appears. In newer versions of the operating system, PowerShell may be replaced by a terminal, but the functionality remains the same.
Alternative option: click Win + R, enter cmd, but instead of simply pressing Enter, use the combination Ctrl + Shift + EnterThis action will force the command to open with elevated privileges. If prompted by the User Account Control (UAC) prompt, click "Yes."
☑️ Check before starting work
View a list of all saved Wi-Fi networks
After successfully launching a black terminal window, the first thing you should do is view a list of all networks that have ever been active on this computer. The system stores these networks as profiles, and each has its own unique name (SSID). To display this list, use the special netsh command.
Type the following line and press Enter:
netsh wlan show profiles
The system will display a list of all saved profiles. Pay attention to the "User Profiles" section. This is where the names of the networks available for viewing are listed. If you see your network in the list, its password is saved in your PC's memory and can be retrieved.
Sometimes the desired network isn't listed. This could mean the profile was previously deleted, or you're using a different user account than the one you used to connect. In this case, recovering the password using this method won't work, and you'll have to look for alternatives, such as checking the sticker on the router.
Obtaining a specific network password via CMD
Once the desired network name is known, the most important step begins. We need to query the system for detailed information about the selected profile, including the security key. This is done using the extended command syntax. netsh wlan with parameter key=clear.
The command syntax is as follows:
netsh wlan show profile name="Network_Name" key=clear
Instead of Network_Name You must enter the exact name of your Wi-Fi network, as displayed in the list in the previous step. If the name contains spaces, quotation marks are required. After entering the command, the system will display a detailed report. We are interested in the "Security settings" section.
In this section, find the "Key Content" line. The value to the right of the colon is your password. Copy it or rewrite it. Pay attention to the case and special characters—they matter when connecting new devices.
⚠️ Attention: If a dash or an error message appears instead of a password in the "Key Contents" line, your current account does not have sufficient privileges, even if the console is running as an administrator. Try logging in with an account with full privileges.
Analysis of security and encryption parameters
The profile output command provides not only the password but also a wealth of other useful technical information. The report shows the encryption type (for example, WPA2-Personal or WPA3), security type, and even the number of connected devices if you have router administrator rights and use additional utilities.
Understanding the encryption type is important for assessing the security of your home network. If you see an outdated standard WEPThis is a signal that your router settings are critically outdated and require updating. Modern standards ensure reliable data protection from interception.
The report may also include the channel frequency and radio module type. This data is useful for diagnosing internet speed or connection stability issues. Knowing the frequency your network operates on can help you optimize your router settings for better coverage.
What should I do if the network name contains special characters?
If your network name contains quotation marks or other special characters that might conflict with CMD syntax, try enclosing the network name in single quotation marks within double quotation marks, or use auto-completion by pressing the Tab key after typing the first letters of the profile name.
Comparison of Password Retrieval Methods: CMD vs. GUI
To fully understand the situation, it's worth comparing the command line method with the classic Windows settings method. Each approach has its advantages and disadvantages, depending on the specific situation and the user's level of experience.
| Characteristic | Command Prompt (CMD) | Graphical user interface (GUI) |
|---|---|---|
| Access speed | High (a few seconds) | Medium (requires menu navigation) |
| Access to history | All saved profiles | Only active or recent |
| Complexity | Requires knowledge of commands | It's intuitive |
| Copying | Convenient (text format) | Difficult (need to look at the screen) |
As the table shows, CMD is superior in terms of versatility and speed when working with a large number of profiles. The graphical interface is suitable for one-time actions when the user is concerned about making syntax errors. However, once you master the basic commands, you gain a powerful administration tool.
It's important to note that the settings interface may differ across different Windows 10 builds. Microsoft is constantly updating the design of the Settings menu, moving items around. Commands netsh remain unchanged over many years, making this method reliable and predictable.
Possible errors and solutions
While following these instructions, users may encounter various system error messages. These are most often related to typos in the network name or insufficient access rights. Let's look at the most common issues and how to resolve them.
The "The wireless network profile is not found" error occurs if you entered the network name incorrectly. In Windows, case is important, and spaces are also important. To avoid errors, copy the network name from the list returned by the command. show profiles, and paste it into the key view command.
If the system displays "Access is denied," it means the console is not running as an administrator. Close the window and try running it again, making sure to select "Run as administrator." Without this step, viewing security keys is impossible due to OS security policy.
⚠️ Attention: Antivirus software or corporate security policies (Group Policy) may be blocking netsh commands. If you're working on an office computer, contact your system administrator.
Frequently Asked Questions (FAQ)
Is it possible to find out a Wi-Fi password if the computer is not connected to it right now?
Yes, you can. The command line accesses a database of saved profiles. If you've ever successfully connected to this network and haven't deleted the profile, the password is saved in the system and can be viewed via key=clear.
Is it safe to use the command line for this purpose?
It is completely safe if you use standard Windows commands. Command netsh is a Microsoft system utility and is virus-free. However, be careful with commands you copy from untrusted sources online.
What should I do if the required network is not in the list of profiles?
This means the profile was deleted, or the connection was made from a different user account on the same PC. In this case, you won't be able to recover the password using CMD. Try finding the password on the router's sticker or accessing the router settings through a browser.
Does this method work on Windows 11?
Yes, the method is completely identical. Windows 11 retains compatibility with the command line utilities from Windows 10, so all the commands described work without changes.