Home › Topics › Certificate & Expiry Monitoring › Expiry Monitoring

Monitoring Certificate Expiry: Checks That Fire in Time


A certificate expiry is the only outage in IT that sends you a save-the-date. The moment it will fail is written inside the certificate, readable by anyone, from the day it is issued. So monitoring expiry is not detection. There is nothing to detect yet. It is the job of turning a known future date into an alert that fires early enough for the renewal work that certificate needs. That alert is aimed at a person who will actually do the work.


Each part of that job hides a way to get it wrong. Check the wrong thing, a file on disk instead of what the network serves, and you are monitoring a fiction. Use one warning window for everything and the alert fires so early it gets snoozed or so late the paperwork cannot finish. Send it to a shared mailbox and it becomes a countdown nobody hears. I have made all three mistakes myself, which is how I know the order they hurt in. This guide covers the whole path. It explains what an expiry check really does and why it must validate the chain and not just the one certificate. It shows how to tier warning windows by renewal effort and how to route alerts to owners. It also covers the one check almost everyone forgets — the day after the renewal.


You will need a certificate inventory to aim these checks at. If you have not built one yet, start with building a certificate inventory and come back. The register and the monitoring are two halves of one machine.


In this guide

  • What an expiry check actually does
  • Check the chain, not just the leaf
  • Warning windows tiered by renewal effort
  • Route the alert to an owner
  • Internal and self-signed certs need the same checks
  • Watch the clock and the domain too
  • The day-after check
  • Where to go next

What an expiry check actually does


The honest version of a certificate check is simple. Connect to the service exactly like a real client, read the certificate it presents, and do arithmetic on the dates inside. The connection part matters more than the arithmetic. A certificate is not really "the file on the server" — it is whatever the service hands to connecting clients. That can differ from the file on disk for all sorts of mundane reasons. For example, the service was never reloaded after a new certificate was installed. Or a load balancer in front is serving its own older copy. Or the wrong certificate is bound to that port entirely. A service serves whatever it loaded at startup, not whatever you copied over since, and it does not go back to check. Checking over the network measures the thing users actually experience.


Every serious monitoring tool has this check built in. You point it at a host and port. It reports days-remaining as a number you can alert on. See the raw version once anyway, because it shows exactly what the tool is doing. The standard OpenSSL toolkit, present on practically every Linux box and easily available on Windows, can perform the whole check in one line:


echo | openssl s_client -connect www.example.com:443 -servername www.example.com 2>/dev/null | openssl x509 -noout -checkend 2592000
Certificate will not expire

Reading it left to right: s_client opens a TLS connection to the host and port, like a browser would. The -servername option matters: it sends SNI (Server Name Indication). This part of the handshake tells a server hosting several sites which one you want. Omit it and you may be handed a different certificate than your users get. The second command reads the presented certificate. And -checkend asks one question: will this certificate still be valid this many seconds from now? Here that is 2,592,000 seconds, thirty days. The command prints its answer and sets an exit code, which is what makes it scriptable. Swapping -checkend for -dates prints the raw validity timestamps instead. And -subject -issuer shows whose certificate it is and who signed it. That is useful when what is being served is not what you expected.


Two placement details save real pain. First, check from where your clients are. A certificate can look fine from inside the network while the outside world, arriving through a load balancer or reverse proxy, is served something else. If a service matters both internally and externally, check it from both sides. Second, check every node that can serve the certificate. Suppose a high-availability pair has a fresh certificate on the primary and a forgotten one on the standby. It passes every check for months, then fails at the worst possible moment: mid-failover.


A word on frequency and record-keeping. Once a day is the right cadence for expiry checks. The number only changes by one per day, so checking every five minutes is superstition. The gentle pace means the checks cost your services nothing. Record the days-remaining value as a metric rather than a pass/fail, because the number tells stories a status light cannot. A fleet view sorted by days-remaining is an instant work queue. And a value that suddenly increases is a renewal landing. As you will see in the day-after section, that is worth watching for on purpose.


Check the chain, not just the leaf


Recall the structure from why certificate outages keep happening. Your server's certificate (the leaf) is signed by an intermediate certificate. That intermediate is signed by a root in the client's trust store. Clients validate the whole chain, and every link has its own expiry date. This means the arithmetic-on-one-date version of the check has a blind spot. The leaf can have plenty of runway while a certificate above it in the chain is about to die.


An expiring intermediate is a much rarer event than an expiring leaf. But its blast radius is brutal: every certificate signed under it fails at the same moment. For a public CA that is the CA's problem to rotate in good time. But it becomes your problem in two common ways. First, many servers are configured to send the intermediate alongside the leaf (the "bundle" or "chain file"). That copy is static. If your bundle contains an old intermediate, your service can present an expired chain. That can happen even though the leaf is fine and the CA long since published a newer intermediate. Second, if you run an internal CA, its issuing certificate is your intermediate. In that case, nobody rotates it but you. That is the meta-expiry problem covered in running an internal CA.


The fix is to make the monitoring check validate like a client instead of just reading one date. Verify the presented chain against a trust store and read the dates on every certificate in it, alerting on the soonest. Good monitoring checks do this. The OpenSSL output shows the full chain too if you ask. While you are at it, alert on validation failures generally — wrong name on the certificate, incomplete chain, untrusted issuer. Each of those is a user-facing error with a countdown of zero.


Warning windows tiered by renewal effort


How early should the alert fire? The lazy answer is one global number, and it is wrong in both directions at once. A certificate that renews itself needs only a short window. Alerting a month out on something a robot fixes nightly just trains people to ignore the alert. A certificate that requires a purchase order, a vendor's validation paperwork, and a change-window to install needs months of runway. For that certificate, a thirty-day warning is an outage announcement with extra steps. The window must match the work, and the renewal-method field in your inventory is exactly where that answer lives.


Renewal pathTypical exampleFirst warningUrgent alertWhy this window
Automated protocolWeb certs renewed by an issuance agentWhen renewal is overdue (it should have happened well before expiry)2 weeks leftYou are not alerting on expiry — you are alerting on broken automation
Scripted manualAdmin runs a tested renewal script30 days14 daysThe work is an hour; the window covers vacations and busy weeks
Manual, simple purchasePortal login, pay, download, install45 days21 daysCovers approval of a small spend plus scheduling the install
Manual with vendor paperworkOrganization-validated certs, code signing90 days45 daysVendor-side verification can stall for weeks; you cannot rush it
Appliance / maintenance windowDevice certs needing scheduled downtimeOne full maintenance cycle aheadNext-to-last windowMiss one change window and you must still have another before expiry

Treat those numbers as starting points and tune them the honest way. After each renewal, note whether the first warning left comfortable slack. Adjust that row's window rather than the global default. Make the alerts escalate as the date approaches. Use a warning at the first threshold, a louder alert at the urgent one, and a daily drumbeat in the final week. That drumbeat does not stop until the renewed certificate is verified in place. Expiry countdowns are one of the few alerts where repetition is a feature: the problem genuinely worsens every single day it is ignored.


Warning: never snooze a certificate alert without booking the work. Snoozing an expiry warning is not deferring a notification — it is scheduling the outage and agreeing not to be reminded. If the alert fired too early to act on, that is a tuning problem. In that case, shorten the window in the register so the alert stays meaningful, rather than teaching yourself to dismiss it.


Route the alert to an owner


An expiry alert nobody owns is a countdown nobody hears. The classic outage rarely lacks a warning — it lacks a recipient. The reminder went to a departed admin's mailbox, or to a shared alias where everyone assumed someone else would deal with it. Monitoring you run yourself fixes the dead-mailbox half automatically, but it recreates the shared-alias half beautifully if every certificate warning lands in one team-wide inbox.


The inventory already names an owner for every certificate. Make the alert routing use it. The person who renews the mail certificate gets the mail certificate's warnings. The web team gets the web ones. The register itself says who. Then add the two safety layers any long-running countdown needs. Escalate on silence. If the owner has not acknowledged within a few days, notify their backup and then their manager. This is not punishment. Vacations, departures, and overflowing inboxes are exactly the failure modes this system exists to survive. And convert acknowledgment into work. An expiry warning is not news to file. It is a task with a hard deadline, so it belongs in whatever system tracks your team's work the moment it is acknowledged. The alert's job is to start the renewal, and it has not succeeded until that happens.


Keep the certificate vendors' own reminder emails switched on too, pointed at a role address your team genuinely reads. But treat them as the backup channel, never the primary. Vendor reminders stop when the account contact goes stale. They cover only the certificates bought through that vendor. They know nothing about your internal or self-signed certificates. Your own monitoring covers everything in the register, from one place, with routing you control. Two independent channels that both have to fail is a fine safety design. One channel owned by someone else is how the classic outage was built.


Internal and self-signed certs need the same checks


There is a tempting mental shortcut: public certificates get monitoring because customers see them; internal ones are somebody's intranet problem. The shortcut is exactly backwards about who gets warned. A public website's expiry is at least loudly visible — browsers make sure of that. An internal certificate expires in silence, because the things connecting to it are often not humans with browsers but service accounts, scheduled jobs, agents, and devices. Nothing shows a warning page to a backup job. It simply fails, and the error says "connection error," not "certificate expired," and someone burns an evening tracing it.


So the rule is uniform: every certificate in the register gets a check, whoever issued it. Certificates from your internal CA are monitored exactly like public ones — connect, validate the chain against your root, read all the dates. Self-signed certificates get checked too. They have expiry dates like anything else, frequently absurd ones chosen by an appliance's firmware. The register is where you decided whether each one matters. The one honest difference is windows: internal certificates often renew via quick internal processes. So their tiers can be shorter — but that is a tuning difference, not an exemption.


At Meridian Parts the directory server's certificate, the one applications used for secure LDAP lookups, expired on a Tuesday night. By Wednesday morning the badge system was flaky, two internal apps refused logins, and the print server was misbehaving. Each raised a separate ticket that mentioned neither certificates nor the directory. The common cause sat three layers below the symptoms, invisible to any browser. It was found late in the afternoon by someone reading the right log closely. One daily check against the directory server's TLS port, thirty seconds to configure, would have turned that whole day into a routine renewal two weeks earlier. The team added the check that evening, and it has fired twice since, which is two Wednesdays that did not happen.


Watch the clock and the domain too


Two adjacent checks belong in the same monitoring pass, because they fail the same way and are cheap to add. The first is time itself. Certificate validation is a comparison between dates in the certificate and the clock on whatever machine is checking — including your monitoring server. A monitoring host whose clock drifts will raise false alarms about valid certificates or, worse, stay silent past a real expiry. A client fleet with drifting clocks generates "certificate error" tickets against perfectly healthy services. Keeping every clock disciplined with NTP, and monitoring that it stays disciplined, quietly underwrites every check in this guide. The guide on monitoring NTP covers how.


The second is domain expiry. Your registrar records an expiry date for each domain you own. That date outranks every certificate on the domain. When the domain lapses, DNS fails, mail dies, and every certificate on those names becomes decoration. Most registrars expose the date in their portal and through standard lookup services. Monitoring tools can alert on it just like a certificate date. Give domains long windows. Renewal is trivial, but the failure is so severe that you want the backstop far out. Keep them in the same register, as covered in building a certificate inventory.


The day-after check


Here is the failure mode that embarrasses teams who did everything else right: the renewal that never reached production. The alert fired, and the owner acted. The vendor portal says renewed, the invoice is paid, and everyone relaxes. But the server keeps serving the old certificate, because the new one was never installed. Or it was installed but the service was never reloaded. Or it went to one node of the pair, or to three of the four places the register lists. Weeks later the old certificate expires on schedule, and the outage arrives wearing a "we already fixed this" hat.


The cure is a small ritual: after any renewal, verify from the network that the new certificate is actually being served everywhere it should be. It takes five minutes:


  • 1. Connect to every host:port the register lists for this certificate — every node, every side of the load balancer, inside and outside.
  • 2. Confirm the served certificate is the new one: the expiry date moved out, and the serial number changed.
  • 3. Confirm the full chain validates — a renewal is the classic moment for an old intermediate to sneak into the bundle.
  • 4. Reload or restart anything still serving the old certificate; many services load certificates only at startup.
  • 5. Watch the monitoring go green on its own next cycle, and update the register row: new expiry, new date in "last verified."

Notice that your normal expiry monitoring nearly gives you this for free. If the check runs daily and reads days-remaining, a successful deployment shows up as the number jumping upward. Some teams alert on exactly that — "renewal was performed but days-remaining did not increase within a day". That converts the renewed-but-not-deployed classic from a lurking surprise into a same-day notification. Be one of those teams. It is the cheapest alert you will ever configure, and it catches the one mistake a careful person makes.


Where to go next


Connect like a client and validate the whole chain. Tier the windows by renewal effort and route every alert to a named owner. Treat internal certificates as first-class. Watch the clocks and the domains, and verify the day after. That is the complete discipline, and it turns certificate expiry into what it always should have been: scheduled maintenance with a generous warning. The next step is shrinking the manual work those alerts trigger. Automating Renewals: From Calendar Reminders to Zero-Touch climbs that ladder rung by rung. The rest of the Certificate & Expiry Monitoring guides cover the inventory and internal CA foundations that ladder stands on. The save-the-date went out the day the certificate was issued. All of this is just making sure somebody opens it.


Put this into practice with SysPeep Monitor

Expiry checks only help if they run every day and reach the right person, which is a job for software rather than willpower. SysPeep Monitor runs on one Windows machine and watches the services on your network. Its threshold-based alert rules and email notifications are built to fire early and escalate without drowning you in noise. The free trial installs in minutes.

Download Free TrialLearn About SysPeep