ssl-guides 2026-12-02 ⏱ 2 min read

Convert CRT to PEM

Convert CRT to PEM
Quick Answer: A .crt file is often already PEM, so just rename it to .pem. If it is binary (DER), convert it with openssl x509 -inform DER -in certificate.crt -out certificate.pem -outform PEM.

Check the format first

Extensions like .crt and .cer only say "certificate". They do not tell you the encoding.

head -n 1 certificate.crt
What you seeFormatAction
-----BEGIN CERTIFICATE-----PEM (text)Rename to .pem if needed
Unreadable binary charactersDER (binary)Convert with OpenSSL

CRT to PEM: convert DER to PEM

openssl x509 -inform DER -in certificate.crt -out certificate.pem -outform PEM

You can reverse it:

openssl x509 -in certificate.pem -outform DER -out certificate.der

The free SSL Converter does the same without the command line.

Inspect the result

openssl x509 -in certificate.pem -noout -subject -issuer -dates

This prints who the certificate is for, who issued it and when it expires. You can also paste it into the SSL Decoder.

CRT to PEM: build a chain file

Servers such as Nginx expect the leaf certificate first, followed by the intermediates, all in PEM:

cat certificate.pem intermediate.pem > fullchain.pem

Check the result with the SSL Checker after installing. If your CA gave you a .p7b file, extract the certificates with:

openssl pkcs7 -print_certs -in bundle.p7b -out bundle.pem

Common mistakes

  • Trying to convert a file that is already PEM, which gives an "unable to load certificate" error with -inform DER.
  • Mixing up the certificate and the key. The key starts with -----BEGIN PRIVATE KEY----- or BEGIN RSA PRIVATE KEY.
  • Extra spaces or Windows line endings in a pasted file.
  • Forgetting the intermediate, which leads to chain errors.

Need a PFX instead?

For IIS and Windows see our PEM to PFX guide. If you are creating a new certificate, you can start at TryFreeSSL.com, or generate a request with the CSR Generator.

Related reading: converting PFX to PEM, generating a key and CSR and the certificate chain.

Frequently Asked Questions

Is CRT the same as PEM?

Not by definition. CRT is an extension. The content is usually PEM but can be DER.

Can I just rename the file?

Only if it is already PEM text. Renaming a DER file does not change its encoding.

Does conversion change the certificate?

No. It only changes the encoding, the signature and contents stay the same.

Which format does Nginx want?

PEM, with the leaf first and then the intermediates.

🔄 Convert PEM Certificate to Windows .PFX Online
Convert PEM → PFX →

✅ Post-Installation Verification & SEO Checklist

After applying the steps above, run through this 5-point checklist to prevent browser warnings and protect your Google SEO rankings:

  • Verify full CA chain trust and TLS 1.3 support using our Live SSL Checker.
  • Scan for Mixed Content HTTP links and check HSTS/CSP headers on Security Headers Checker.
  • Enforce a permanent 301 HTTP-to-HTTPS redirect with our HTTPS Redirect Generator.
  • Confirm both root and www versions resolve cleanly to one canonical HTTPS URL.
  • Verify your HTTPS property and sitemap.xml inside Google Search Console and Bing Webmaster Tools.
Technically Reviewed by TryFreeSSL Security Team
Last updated: 2026-12-05
About Us →

Free SSL Certificates, Live SSL Checker & CSR Generator

Issue trusted Let's Encrypt SSL certificates in 60 seconds with zero server setup.

Related Articles

🤖 TryFreeSSL AI Assistant