opdeck / blog / check-if-website-ssl-certificate-is-valid-guide

How to Check If a Website's SSL Certificate is Valid with OpDeck

August 11, 2026 / OpDeck Team
SSL CertificateWebsite SecurityOpDeckHTTPS ValidationWeb Development

If you need to check if a website's SSL certificate is valid, you've come to the right place. Whether you're a site owner making sure your own HTTPS setup is working correctly, a developer debugging a connection issue, or a security-conscious user who wants to verify a site before entering sensitive information, confirming SSL certificate validity is a straightforward process — once you know the right tools and what to look for. This guide walks you through everything: what makes an SSL certificate valid, how to check it quickly with OpDeck's SSL Certificate Checker, and how to interpret the results so you can take action immediately.


What Does It Mean for an SSL Certificate to Be Valid?

Before diving into the how-to, it helps to understand what "valid" actually means in the context of SSL certificates. An SSL (Secure Sockets Layer) certificate — more accurately called a TLS certificate in modern usage — is a small digital file installed on a web server that does two things: it encrypts the connection between the server and the visitor's browser, and it authenticates the identity of the website.

For an SSL certificate to be considered valid, it must meet several specific criteria simultaneously:

1. It Must Not Be Expired

Every SSL certificate has a defined lifespan. Historically, certificates could be issued for up to three years. As of 2020, the maximum validity period was reduced to 398 days, and there are ongoing industry discussions to reduce this further to 90 days. When a certificate expires, browsers immediately flag the site with a security warning, and many users will simply leave rather than proceed.

2. It Must Be Issued by a Trusted Certificate Authority (CA)

Not all SSL certificates are created equal. A certificate must be signed by a Certificate Authority (CA) that is recognized and trusted by major browsers and operating systems. Well-known CAs include DigiCert, Sectigo, Let's Encrypt, GlobalSign, and others. If a certificate is self-signed — meaning the website owner signed it themselves without going through a recognized CA — browsers will display a warning, even if the certificate is technically functional.

3. The Domain Name Must Match

An SSL certificate is issued for a specific domain name (or a set of domain names using a wildcard or SAN — Subject Alternative Names). If the domain on the certificate doesn't match the domain you're visiting, the browser throws a certificate mismatch error. For example, a certificate issued for www.example.com won't automatically cover shop.example.com unless it's a wildcard certificate covering *.example.com.

4. The Certificate Chain Must Be Complete

SSL certificates work within a chain of trust. Your site's certificate (the "leaf" certificate) must be signed by an intermediate certificate, which is in turn signed by a root certificate trusted by the browser. If any link in this chain is missing or broken — a common misconfiguration — browsers will reject the certificate even if the leaf certificate itself is perfectly valid.

5. It Must Not Be Revoked

Certificate Authorities can revoke certificates before they expire if the private key is compromised or the certificate was issued in error. Browsers check revocation status through mechanisms like OCSP (Online Certificate Status Protocol) or CRL (Certificate Revocation Lists). A revoked certificate is treated as invalid regardless of its expiry date.


How to Check If a Website SSL Certificate Is Valid Using OpDeck

The fastest and most accessible way to check if a website's SSL certificate is valid is to use OpDeck's SSL Certificate Checker. It's a free, browser-based tool that requires no installation, no command-line knowledge, and no technical background. Here's exactly how to use it.

Step 1: Navigate to the SSL Certificate Checker

Go to https://www.opdeck.co/tools/ssl. You'll see a clean input field asking for a domain or URL.

Step 2: Enter the Website Domain

Type in the domain you want to check. You can enter it in several formats:

  • example.com
  • www.example.com
  • https://www.example.com

The tool handles the formatting for you, so don't worry about including or excluding the protocol prefix.

Step 3: Run the Check

Click the Check button. The tool will connect to the server, retrieve the SSL certificate, and analyze it against all the validity criteria discussed above.

Step 4: Read the Results

Within a few seconds, you'll see a detailed breakdown of the certificate. Here's what each section tells you:

Certificate Status — A clear valid/invalid indicator at the top. This is the quick answer to your question.

Issuer Information — The name of the Certificate Authority that issued the certificate. You'll see the CA's common name, organization, and country. This tells you immediately whether the cert comes from a trusted authority.

Validity Period — The exact "Not Before" and "Not After" dates. You can see precisely when the certificate was issued and when it expires. OpDeck also shows you how many days remain until expiration, which is enormously useful for proactive monitoring.

Subject / Domain Coverage — The domain(s) the certificate covers. If you're checking a wildcard certificate, you'll see the wildcard pattern (e.g., *.example.com). For multi-domain certificates, all covered domains are listed under the Subject Alternative Names.

Certificate Chain — Whether the full chain of trust is intact, including intermediate certificates.

Fingerprint — The SHA-256 fingerprint of the certificate, which you can use to verify the certificate hasn't changed unexpectedly (useful for security audits and certificate pinning verification).


Checking SSL Certificate Validity via the Command Line

For developers and system administrators who prefer working in the terminal, there are several command-line methods to check SSL certificate validity. These are particularly useful for scripting, automation, or checking certificates on non-public servers.

Using OpenSSL

OpenSSL is the gold standard for SSL/TLS inspection from the command line. It's available on macOS, Linux, and Windows (via WSL or Git Bash).

To retrieve and display a site's certificate:

openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -text

This command dumps the full certificate details. To focus specifically on the validity dates:

openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -dates

The output looks like this:

notBefore=Jan  1 00:00:00 2024 GMT
notAfter=Dec 31 23:59:59 2024 GMT

To check just the issuer:

openssl s_client -connect example.com:443 -servername example.com </dev/null 2>/dev/null | openssl x509 -noout -issuer

To verify the full certificate chain:

openssl s_client -connect example.com:443 -servername example.com -verify_return_error </dev/null

If the chain is valid, you'll see Verify return code: 0 (ok) near the end of the output. Any other code indicates a problem.

Using curl

curl is another widely available tool that can quickly tell you if a certificate is valid:

curl -vI https://example.com 2>&1 | grep -E "SSL|certificate|expire|issuer"

If the certificate is valid, you'll see lines like:

* SSL connection using TLSv1.3 / TLS_AES_256_GCM_SHA384
* Server certificate:
*  subject: CN=example.com
*  start date: Jan  1 00:00:00 2024 GMT
*  expire date: Dec 31 23:59:59 2024 GMT
*  issuer: C=US; O=Let's Encrypt; CN=R3
*  SSL certificate verify ok.

That final line — SSL certificate verify ok. — is the confirmation you're looking for.

If the certificate is invalid (expired, self-signed, mismatched domain, broken chain), curl will return an error like:

curl: (60) SSL certificate problem: certificate has expired

Using nmap

For a more security-focused check, nmap with the ssl-cert script provides detailed certificate information:

nmap --script ssl-cert -p 443 example.com

Checking SSL Certificates in Your Browser

You don't always need an external tool. Modern browsers give you direct access to SSL certificate information, though the process varies slightly between browsers.

In Chrome or Edge

  1. Click the padlock icon (or the tune icon in newer Chrome versions) in the address bar
  2. Click Connection is secure
  3. Click Certificate is valid

A popup window will display the certificate's issuer, validity dates, and subject information.

In Firefox

  1. Click the padlock icon in the address bar
  2. Click the right arrow next to "Connection secure"
  3. Click More information
  4. In the Page Info window, click View Certificate

Firefox opens a dedicated certificate viewer tab with full chain details.

In Safari

  1. Click the padlock icon in the address bar
  2. Click Show Certificate

The browser-based approach is fine for a quick spot check, but it has limitations: you can't easily compare certificates over time, you can't check certificates for domains you're not actively visiting, and you don't get structured data you can save or share. That's where a dedicated tool like OpDeck's SSL Certificate Checker adds real value.


Common SSL Certificate Problems and What They Mean

When you check if a website's SSL certificate is valid and find issues, here's how to interpret the most common errors:

"Certificate Has Expired"

The most common SSL problem. The fix is straightforward: renew the certificate. If you're using Let's Encrypt, this should happen automatically via certbot or your hosting provider's auto-renewal system. If it's a paid certificate, you'll need to purchase a renewal and reinstall it. Always check expiry dates at least 30 days in advance.

"Certificate Is Not Trusted" or "Self-Signed Certificate"

This means the certificate wasn't issued by a recognized CA. For production websites, you should always use a certificate from a trusted CA. Let's Encrypt provides free, trusted certificates. Self-signed certificates are acceptable for internal development environments but should never be used on public-facing sites.

"Certificate Domain Mismatch"

The domain in the certificate doesn't match the URL you're visiting. Common causes include:

  • Visiting a subdomain not covered by the certificate
  • A misconfigured redirect sending traffic to a different domain
  • A wildcard certificate that doesn't cover the specific subdomain pattern

"Incomplete Certificate Chain"

The server isn't sending the intermediate certificate(s). This is a server configuration issue. The fix is to include the full certificate chain in your server configuration. In Nginx, this means concatenating your certificate with the intermediate certificate in a single .pem file. In Apache, you use the SSLCertificateChainFile directive (older versions) or include intermediate certs in the main certificate file.

"Certificate Has Been Revoked"

This is rare but serious. It typically means the private key was compromised. The immediate fix is to request a new certificate from your CA and install it. Investigate how the private key may have been exposed.


Why Regularly Checking SSL Certificate Validity Matters

Letting an SSL certificate expire is one of the most avoidable yet surprisingly common website problems. When it happens, the consequences are immediate and significant:

  • Visitors see a scary security warning — most will leave immediately rather than click through
  • Search engine rankings can be impacted — Google has used HTTPS as a ranking signal since 2014, and a broken certificate effectively downgrades your site
  • API integrations break — if your site's certificate expires, any service making HTTPS requests to your API will receive errors
  • Trust is damaged — even after you fix the certificate, some users may hesitate to return

Setting up regular checks is the best defense. Many teams set up monitoring scripts using the OpenSSL command above in a cron job, with alerts when certificates are within 30 days of expiry. Others use dedicated monitoring services. At minimum, make it a habit to run a quick check through OpDeck's SSL Certificate Checker whenever you're doing any kind of site audit or maintenance.


Automating SSL Certificate Expiry Monitoring

If you manage multiple websites, manual checks don't scale. Here's a simple shell script that checks multiple domains and alerts you when a certificate is expiring within 30 days:

#!/bin/bash

DOMAINS=("example.com" "anotherdomain.com" "myapp.io")
ALERT_DAYS=30

for DOMAIN in "${DOMAINS[@]}"; do
  EXPIRY=$(echo | openssl s_client -connect "$DOMAIN:443" -servername "$DOMAIN" 2>/dev/null \
    | openssl x509 -noout -enddate 2>/dev/null \
    | cut -d= -f2)

  if [ -z "$EXPIRY" ]; then
    echo "WARNING: Could not retrieve certificate for $DOMAIN"
    continue
  fi

  EXPIRY_EPOCH=$(date -d "$EXPIRY" +%s 2>/dev/null || date -j -f "%b %d %T %Y %Z" "$EXPIRY" +%s)
  NOW_EPOCH=$(date +%s)
  DAYS_LEFT=$(( (EXPIRY_EPOCH - NOW_EPOCH) / 86400 ))

  if [ "$DAYS_LEFT" -le "$ALERT_DAYS" ]; then
    echo "ALERT: $DOMAIN certificate expires in $DAYS_LEFT days ($EXPIRY)"
  else
    echo "OK: $DOMAIN certificate valid for $DAYS_LEFT more days"
  fi
done

Run this script daily via cron (0 8 * * * /path/to/ssl-check.sh) to stay ahead of expirations.


Conclusion

Knowing how to check if a website's SSL certificate is valid is an essential skill for anyone who manages, develops, or regularly uses websites. A valid SSL certificate is not optional — it's foundational to user trust, data security, and search visibility. Whether you use a browser's built-in certificate viewer, OpenSSL on the command line, or a dedicated tool, the important thing is that you're checking regularly and acting on what you find.

For the fastest and most complete way to check if a website's SSL certificate is valid, use OpDeck's SSL Certificate Checker. It gives you a full picture of certificate status, expiry, issuer, domain coverage, and chain validity in seconds — no technical setup required. Head over to opdeck.co to run your first check right now, and explore the rest of OpDeck's web analysis toolkit while you're there.