The .ssh folder is where Windows OpenSSH usually keeps your SSH keys and configuration files for connecting to remote computers, Git services, and servers. On Windows 10 and 11, it is normally inside your user profile. This guide shows how to open the folder in File Explorer or find it with a command, and what to check if it is not there. You do not need to install anything just to look for it.
What You’ll Need
- A Windows account with access to the profile where the SSH files were created. If the files belong to another account, you may need to sign in to that account.
- File Explorer, or a terminal such as PowerShell or Command Prompt. These are included with Windows.
- The account name or location used when the SSH key was created, if you are looking for a key made on a different computer, under another Windows account, or in WSL.
You do not need administrator rights to view your own .ssh folder. Avoid opening or sharing private key files unless you know why you need them; anyone who obtains an unprotected private key may be able to use it.
Step-by-Step
-
Open File Explorer. Select the folder icon on the taskbar, or press
Windows key + E. File Explorer is the simplest option if you want to browse the files visually. -
Go to your user profile. Click the address bar at the top of File Explorer, type
%USERPROFILE%, and press Enter. Windows expands that variable to your current account’s profile folder, usually something likeC:\Users\Morgan. The folder name may not match your full name or Microsoft account email. -
Look for the
.sshfolder. In the profile folder, check the list of folders for.ssh. The usual full path isC:\Users\your-name\.ssh. The leading period is part of the folder name. Windows does not automatically treat every name beginning with a period as hidden, so you normally do not need to change a hidden-items setting to see this folder. -
Open the folder directly if you prefer. In File Explorer’s address bar, enter
%USERPROFILE%\.sshand press Enter. This takes you straight to the standard location without requiring you to find your profile folder manually. You can also enter the full path, replacingyour-namewith the actual profile folder name. -
Check the contents without changing anything. Common files include
id_ed25519orid_rsa(private keys), the matching.pubfiles (public keys),known_hosts, andconfig. A folder can exist without containing all of these files. Do not rename, move, or delete a key just to confirm that you have found it. -
Use PowerShell to verify the location. Open Start, search for PowerShell, and launch it. Run
Test-Path "$HOME\.ssh". A result ofTruemeans that path exists for the account running PowerShell;Falsemeans it does not. To print the path, runWrite-Output "$HOME\.ssh". You can open the folder in File Explorer from PowerShell withexplorer "$HOME\.ssh". -
Confirm which Windows account you are checking. The standard location is specific to a user. If you opened a terminal as a different account, or used the “Run as administrator” option with different credentials, its home directory may not be the profile you expected. Check the profile shown by
%USERPROFILE%in Command Prompt or$HOMEin PowerShell, then look in that account’s.sshfolder.
In Command Prompt, you can also check the standard location by running dir "%USERPROFILE%\.ssh". If the directory exists, the command lists its contents. If it does not, Command Prompt reports that it cannot find the path; that message does not necessarily mean SSH is broken. It may simply mean no SSH files have been created for that Windows account.
Common Mistakes
- Searching for
.sshin the wrong place. It is normally inside your user profile, not directly inC:\,Program Files, or the Windows installation folder. Start with%USERPROFILE%\.ssh. - Assuming the folder must already exist. Windows does not always create it when OpenSSH is installed. It is commonly made when a key is generated or an SSH program first needs to save a file.
- Checking another account’s profile. Each Windows user can have a separate
.sshdirectory. A key created while signed in as one account will not automatically appear in another account’s profile. - Confusing Windows SSH with WSL SSH. Windows and the Windows Subsystem for Linux (WSL) can have separate home directories and separate SSH files. A Linux shell’s
~/.sshusually refers to the Linux user’s home, notC:\Users\your-name\.ssh. - Thinking the folder is hidden because its name starts with a dot. That convention is familiar on Linux, but it does not by itself make the folder a hidden item in Windows. If File Explorer cannot open the path, check whether it exists and whether you are in the right profile.
- Opening or sharing a private key as if it were a public key. A filename such as
id_ed25519is normally private;id_ed25519.pubis its public counterpart. Keep private keys confidential and do not paste their contents into support requests or public websites.
Tips
- Use the environment-variable path. Typing
%USERPROFILE%\.sshin File Explorer avoids guessing the account folder name and works even when Windows stores your profile on a different drive. - Check file extensions carefully. Public-key files commonly end in
.pub. If extensions are not visible, turn on File Explorer’s file-name extension display so you can distinguish a private key from its public-key file. Do not infer that two similarly named files are interchangeable. - Keep a note of which tool created the key. OpenSSH, Git for Windows, an IDE, and other applications may use different SSH programs or configured key paths. If a tool cannot find a key in the default folder, inspect that tool’s SSH settings before moving files.
- Use a full path when configuring software. If an application asks for a key location, provide the actual path to the private-key file, not just the
.sshdirectory. Confirm the selected file with the application’s documentation. - Protect backups. If you back up your SSH folder, secure the private keys and any passphrases. A public key is designed to be shared with a service, but a private key is not.
Troubleshooting
File Explorer says the location is unavailable or cannot be found. First open %USERPROFILE% by itself. If that works, check the spelling of .ssh and try the full path again. If the direct path still fails, the folder may not have been created yet. Verify with Test-Path "$HOME\.ssh" in PowerShell. A False result confirms that the folder is absent at that particular path.
The folder is missing, but you expected to have SSH keys. Check which account and application created them. Look at the SSH client or Git application’s settings for a custom key path, and check whether the key was created in WSL or on another computer. Do not search the entire drive and assume the first file named id_rsa belongs to the account you need; verify the path and key purpose before using it.
You need the folder but it does not exist. If you intend to create a new key, Windows includes OpenSSH on many current installations. In PowerShell, you can create a key with ssh-keygen; follow its prompts and choose a secure passphrase if appropriate. The default key-generation flow creates the .ssh directory if needed and asks where to save the key. Read each prompt before accepting a path, especially if you already have keys. Creating a key is not necessary simply to locate an existing folder.
You get an access-denied message. Make sure you are signed in as the account that owns the folder. If the folder belongs to a different user, use that account rather than changing permissions casually. Do not take ownership of system or other users’ files unless you have authorization and understand the consequences.
A tool still cannot find the key after you locate it. The tool may be using a different SSH executable, account, or key configuration. Check its settings and any SSH configuration file at .ssh\config. A path listed there may override the default. Make a backup before editing configuration, and never remove a key to troubleshoot a path issue.
Frequently Asked Questions
Where is the .ssh folder in Windows 10 or 11?
The usual location is C:\Users\your-Windows-user-name\.ssh. Enter %USERPROFILE%\.ssh in File Explorer to go to the current account’s default location.
Why don’t I have a .ssh folder?
It may not have been created because you have not generated or used an SSH key with that Windows account. It may also be under another account, inside WSL, or at a custom path chosen by an application.
Is .ssh a hidden folder in Windows?
Not just because it starts with a period. Windows does not use the leading dot alone as a hidden-file setting. If it is absent from your profile, check the direct path and confirm that the folder exists.
Can I create the .ssh folder myself?
Yes. If you only need an empty directory, create a folder named .ssh inside your user profile. If you need a key pair, use an SSH key-generation tool such as ssh-keygen rather than creating key files manually.
Is the Windows .ssh folder the same as WSL’s .ssh folder?
Usually not. WSL’s ~/.ssh is in the Linux user’s home directory, while Windows OpenSSH commonly uses C:\Users\your-name\.ssh. Check which environment created the key and which one your application uses.
Which files in .ssh are safe to share?
Files ending in .pub are public keys and are commonly added to services or servers. Files without that suffix, such as id_ed25519, are typically private keys and should be kept secret. When uncertain, do not share the file.