# Check a certificate (`mttr_ssl_check`)

Updated October 24, 2026.

## What does mttr_ssl_check do?

Checks one public host’s SSL certificate with a single TLS handshake: whether it is valid for the name, who issued it, the days left, the chain as sent and whether it verifies, the TLS version agreed, whether TLS 1.0 and 1.1 are still let in, and whether http:// moves to https:// with HSTS. Any key may make this call, on any public site.

Who may call it: Any key.

## When to use it

- Before a certificate expires, or after it was renewed, to see the new one is served.
- A browser, a crawler or an app refuses the site and you want to know why.

## What you ask

You might say: “Is the certificate on example.com valid, and when does it expire?”

```
mttr_ssl_check({ host: "host" })
```

| Argument | Type | Needed | What it is |
| --- | --- | --- | --- |
| `host` | Text | Yes | The host to check, such as example.com or www.example.com. A full address is taken too, and only its host is used. |

## What comes back

- Each finding with its state in a word, and what to do when something is wrong.
- The certificate: names it covers, issuer, dates, key and signature.
- The chain as sent, and the version and cipher agreed.
- Only the handshake is sent on port 443; public addresses only.

A sample, with made-up sites and figures:

| Check | State | What it means |
| --- | --- | --- |
| Name | Matches | The certificate names example.com |
| Dates | Expires soon | Renew it within 18 days |
| Chain | Trusted | It verifies to a trusted root |
| TLS 1.0 and 1.1 | Refused | As they should be |

## Over HTTP

```
curl "https://mttr.si/api/v1/check/ssl?host=host" \
  -H "Authorization: Bearer $MTTR_KEY"
```

## When it fails

| When | Status | What to do |
| --- | --- | --- |
| Your assistant has no key yet | 401 over MCP | Sign up with `mttr_signup`, then connect again with the key it gives. |
| The key has used this hour’s free checks | 429 | The answer says ssl checks are limited to an hourly allowance. Try again within the hour. |

## Sources

- [Model Context Protocol: tools](https://modelcontextprotocol.io/specification/2025-06-18/server/tools), Model Context Protocol: How an assistant calls a tool.

The call in full: [mttr_ssl_check in the API reference](https://mttr.si/docs/reference#mttr_ssl_check).

## Goes with

- [Test an X card](https://mttr.si/docs/tools/x-card.md)
- [One page](https://mttr.si/docs/tools/page.md)
