Importing PFX certificates on Windows
Learn how to import an SSL/TLS certificate from a PFX/PKCS12 file into Windows Server using certlm.msc, MMC, or PowerShell.
Understanding PFX files
A PFX file (Personal Information Exchange, also referred to as PKCS#12) bundles the certificate, the private key, and any required intermediate certificates into a single password-protected file. PFX files are the standard format for migrating certificates between servers or restoring them from backups.
Prerequisites
- Windows Server 2012 or newer (or Windows 10/11)
- Administrator access to the server
- The PFX file and its associated password
Importing via certlm.msc (Recommended)
Modern versions of Windows Server and Windows 10/11 include certlm.msc (Local Machine Certificates) as a direct shortcut to the machine's certificate store.
- Press Windows + R, type
certlm.mscand press Enter. - Expand the Personal folder and right-click on Certificates.
- Select All Tasks → Import...
- Click Next, browse to your PFX file, and click Next.
- Enter the PFX password. Tick Mark this key as exportable if you need to be able to export the certificate from this server again later.
- Select Automatically select the certificate store and click Finish.
Importing via MMC (Legacy Windows versions)
For older systems without the certlm.msc shortcut:
- Press Windows + R, type
mmc.exeand press Enter. - Go to File → Add/Remove Snap-in.
- Select Certificates, click Add, and choose Computer account → Local computer.
- Click OK.
- Navigate to Certificates (Local Computer) → Personal → Certificates.
- Right-click and select All Tasks → Import... and follow the wizard as described above.
Importing via PowerShell
$password = ConvertTo-SecureString -String "DitPassword" -AsPlainText -Force
Import-PfxCertificate -FilePath "C:\certifikat.pfx" -CertStoreLocation Cert:\LocalMachine\My -Password $password
Troubleshooting
- "The password you entered is incorrect": PFX passwords are case-sensitive. Ensure you are using the exact password provided when the file was created.
- Missing private key (no key icon): If the certificate icon does not show a small key symbol, it has been imported without its private key. You will need to re-import using the original PFX file or provision a new certificate.
- Missing intermediate certificates: If the chain is broken after import, ensure you are using a PFX that includes the full certificate chain, or import the intermediate certificates manually into the Intermediate Certification Authorities store.
Strengthen your TLS security
Use IIS Crypto to easily configure secure TLS protocols and cipher suites on your Windows Server.
IIS Crypto TLS configuration guide