How to Convert a CER to PFX

By Shea Laverty

Converting CER files into PFX files enables you to securely back up your certificates and store them off-server. Since the PFX format stores both the certificate and the private key, it can be used to effectively manage your security certificates without clogging your folders with extraneous files. There are several methods for converting CER to PFX, some of which require no coding or programming experience.

OpenSSL

Step 1

Download and install OpenSSL (see Resources).

Step 2

Press "Windows-X" to launch the power user menu, then select "Command Prompt (Admin).

Step 3

Navigate to the folder containing your CER files and their private key file using the Change Directory or "cd" command.

Step 4

Enter the following command, replacing "certificate.pfx," "privateKey.key," "certificate.cer" and "CACert.cer" with the desired output file name and the correct input file names respectively:openssl pkcs12 -export -out certificate.pfx -inkey privateKey.key -in certificate.cer -certfile CACert.crt

Pvk2Pfx

Step 1

Download and install Pvk2Pfx (see Resources).

Step 2

Press "Windows-X" to launch the power user menu, then select "Command Prompt (Admin).

Step 3

Navigate to the folder containing your CER files and their private key file using the Change Directory or "cd" command.

Step 4

Enter the following command to convert the file, replacing all the same placeholder filenames listed in Step 4 of the OpenSSL section, as well as "pvkpassword" and "pfxpassword" with the desired or necessary information:pvk2pfx /pvk pvkfilename.pvk [/pi pvkpassword] /spc spcfilename.cer [/pfx pfxfilename.pfx [/po pfxpassword] [/f]]

SSL Converter

Step 1

Launch a Web browser and navigate to the SSL Shopper SSL Converter (see Resources).

Step 2

Select "Standard PEM" from the "Type of Current Certificate" drop-down menu.

Step 3

Select "PFX/PKCS#12" from the "Type to Convert To" drop-down menu.

Step 4

Click the Browse button and select the appropriate file for the "Certificate File to Convert" and "Private Key File" headings, and the "Chain Certificate File" and "Chain Certificate File 2" headings if appropriate.

Step 5

Enter the password that will be used to lock the PFX file in the "PFX Password" field.

Step 6

Click "Convert Certificate."

CER to PFX Converter

Step 1

Install and launch CER to PFX Converter (see Resources).

Step 2

Click "Browse" and select the CER file you wish to convert.

Step 3

Click "Convert."

Tips & Warnings

  • Many of these tools can be used to convert PFX files back to CER, or convert either format to another certificate format.
  • As PFX files contain both the certificate and the private key file, a resourceful hacker can gain access to both by cracking the password on the CFX file. Storing this file on your server exposes this file to this risk should an intrusion occur.
  • While SSL Converter uses a secure server and maximizes security as much as possible, there is still the risk of interception during transit or that the file may be mined from the company's server, making this option viable but not without risk.