πŸ”’
SSL & TLS

SSL Pinning: What Is It and What Are the Risks?

πŸ“… 12 October 2026 ✏️ 12 October 2026 ⏱ 5 min leestijd

SSL pinning links an app to a specific certificate. Learn how it works, its risks, and when to use it.

SSL pinning is a security technique in which an application only connects to a server if the certificate or public key matches a predetermined value. This protects against man-in-the-middle attacks, but also carries risks: when a certificate is replaced, the app or website can become unreachable. In this article, we explain how SSL pinning works, when to use it, and how to limit the risks.

What exactly is SSL pinning

Normally, a browser or app trusts any valid certificate issued by a recognized certificate authority. With SSL pinning, that trust is limited: the application not only checks whether the certificate is valid, but also whether it exactly matches a certificate or public key that has been predetermined in the code. This prevents an attacker from intercepting a connection, even with a fake but technically valid certificate from a different certificate authority.

The technique is mainly used in mobile apps, banking environments, and systems where extra protection against eavesdropping is necessary. For regular websites with standard web hosting and a valid SSL certificate, SSL pinning is usually not necessary, since the HTTPS protocol already provides strong baseline security.

How SSL pinning works technically

When setting up a secure connection, the server sends its certificate to the client. Normally, the client only checks whether this certificate has been signed by a trusted certificate authority. With SSL pinning, the client adds an extra step: it compares the certificate (or just the public key) with a value stored in advance within the application itself.

There are two commonly used variants. With certificate pinning, the entire certificate is pinned, including the expiration date. With public key pinning, only the public key is stored, which is more flexible during certificate renewal since the key often remains the same. Both methods ensure that connections with unknown or replaced certificates are immediately rejected.

App / ClientCompare withpinned certificateServer

Risks and drawbacks

Although SSL pinning offers extra protection, it also carries concrete risks. The biggest problem arises during certificate renewal: when the server’s certificate changes but the app still expects the old certificate, the connection is completely blocked. Users then see error messages and can no longer use the service until the app is updated.

Other risks include:

  • Delays in emergencies, such as quickly replacing a compromised certificate.
  • Extra maintenance, as developers must update pinning configurations with every certificate change.
  • More difficult debugging, as security tools that inspect traffic can also block the connection.
  • No flexibility when switching to a different certificate authority without an app update.
πŸ’‘ Tip: Preferably use public key pinning instead of certificate pinning, so that routine certificate renewal does not immediately cause problems.

Applying SSL pinning safely

If you still want to use SSL pinning, make sure to implement it carefully with sufficient safety nets. Below is a step-by-step plan to limit the risks.

1

Choose public key pinning

Pin the public key instead of the full certificate, so that routine renewal doesn’t cause issues.

2

Pin multiple keys

In addition to the active key, also store a backup key, so you don’t get stuck immediately if a switch becomes necessary.

3

Plan certificate renewal well in advance

Update pinning configurations before a certificate expires, not after.

4

Build in a fallback

Make sure the app can temporarily work without pinning in extreme cases, so users aren’t completely locked out.

5

Test with every release

Check pinning settings with every app update and every change to the SSL certificate on the server.

For most regular websites and web shops, a well-configured, automatically renewed SSL certificate is sufficient. At Tandata, you can easily set up free SSL via Plesk, including automatic renewal, so you already have solid baseline security without pinning. If you’re still considering SSL pinning for your own app, make sure the server side is stable and predictable, for example by using fixed domain names and reliable hosting.

Frequently Asked Questions

Is SSL pinning the same as HTTPS?

No. HTTPS provides an encrypted connection with certificate validation via certificate authorities. SSL pinning is an extra layer on top of HTTPS that limits trust to a specific, predetermined certificate or key.

Do I need SSL pinning for my website?

Not for most websites. A valid SSL certificate with automatic renewal, such as you can set up via Plesk, already provides strong protection. SSL pinning is mainly used in native apps with heightened security requirements.

What happens if pinning is configured incorrectly?

The application will no longer be able to reach the server, even if the certificate is valid. This leads to connection errors until the app is updated with the correct certificate or key.

Can I combine SSL pinning with regular web hosting?

Yes, SSL pinning operates at the application layer and has no direct impact on the hosting itself. As long as the certificate on the server is managed in a stable and predictable way, pinning can in theory function alongside regular web hosting.

Does SSL pinning also protect email traffic?

SSL pinning is typically applied in apps and not by default in email clients. For secure email traffic, a correctly configured business email environment with TLS is more important than pinning.

Conclusion

SSL pinning offers extra protection against man-in-the-middle attacks by linking apps to a specific certificate or key, but requires careful management. Without proper planning, a certificate change can quickly lead to disruptions. For most websites, a well-managed SSL certificate with automatic renewal, as is standard with modern web hosting, is sufficient.

View web hosting β†’

Was dit artikel nuttig?