echo | openssl s_client -connect example.com:443 -servername example.com 2>/dev/null | openssl x509 -noout -fingerprint -sha256

Category: Web Servers & Proxies

echo | openssl s_client -connect example.com:443 -servername example.com 2>/dev/null | openssl x509 -noout -fingerprint -sha256

Print a certificate's SHA-256 fingerprint

Computes the SHA-256 digest of the certificate, a unique identifier you can compare against the value printed by the CA or a vendor's documentation. Matching fingerprints confirm you are looking at the exact expected certificate. The fingerprint changes on every renewal.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.