> For the complete documentation index, see [llms.txt](https://docs.keeper.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.keeper.io/keeperpam/self-managed-keeper/self-managed-keeper-overview/installation/tls-certificates.md). Agents can also search and read this documentation through its [MCP server](https://docs.keeper.io/~gitbook/mcp).

# TLS Certificates

How Self-Managed Keeper's TLS certificate works, your options for supplying one, and how to verify it's correct.

Self-Managed Keeper terminates TLS at its own front door, a single reverse proxy for all browser, API, and PAM connection traffic. You do not have to do anything to get started: an install with no certificate configured generates its own self-signed certificate and comes up working. That certificate is fine for evaluation, not for production.

### Choose one

|                          | Use when                                           | You need                                                     |
| ------------------------ | -------------------------------------------------- | ------------------------------------------------------------ |
| **Self-signed**          | Evaluating, developing, air-gapped, no DNS         | Nothing. It's the default                                    |
| **Your own certificate** | Production; public, corporate, or internal CA      | A PEM certificate and key; a private root CA when applicable |
| **Let's Encrypt**        | The host has a public DNS name and internet access | A public DNS zone you control                                |

{% hint style="danger" %}
Whichever certificate method is selected, the certificate must cover all 4 names. See [Names your certificate must cover](#names-your-certificate-must-cover).
{% endhint %}

### Self-signed

This is the default. Installing with no certificate configured generates a local certificate authority and a leaf certificate signed by it, with the correct names derived from your deployment's domains. The CA certificate is written to `install/services/local-proxy/ssl/ca.crt` inside the extracted bundle.

Trust the generated `ca.crt`, not the leaf certificate it signs, in each client's operating system or browser. Bypassing a browser's certificate warning does not make the page a trusted secure context: browsers deliberately refuse WebAuthn (Security Key/YubiKey, passkey enrollment) on a page with an untrusted certificate, along with other APIs like clipboard, microphone, and service-worker caching. Trusting `ca.crt`, or switching to a publicly or enterprise-trusted certificate, is the only way to enable the full browser feature set with the generated certificate.

### Your own certificate

Provide a PEM certificate and key during installation (or configure them directly for an existing deployment). Add a private root CA only if the certificate is privately rooted, for example a corporate or internal CA that isn't in public trust stores.

Requirements:

* **PEM format**, and the certificate file must be the full chain: leaf first, then intermediates. A leaf on its own validates in a browser (which caches intermediates) and fails elsewhere. The installer does not reject a leaf-only file, so check this yourself.
* **The first certificate must be an end-entity leaf, not a CA certificate.** A CA certificate used as the leaf breaks PAM tunnels and connections.
* **The leaf must be currently valid and permit TLS server use.**
* **The private key must not be passphrase-protected.**
* **Absolute paths.** These are bind-mounted as files and must be readable where the deployment reads them at startup.

The certificate and key must be given together, and must actually be a matching pair. These checks, and the required names below, are validated before anything starts, with a clear message rather than a silent failure later.

### Let's Encrypt

Let's Encrypt issues a free certificate using the same mechanism as "your own certificate" above, with `certbot` producing the files. It needs the host to have a public DNS name and outbound internet access, so it is not available for an air-gapped install.

The certificate needs several names under your domain (see below), so the DNS-01 challenge is recommended: it issues all of them in one pass and needs no inbound port open. The HTTP-01 challenge works with any DNS provider but needs port 80 reachable from the internet for every name.

Let's Encrypt certificates are short-lived and renewal is not automatic; you're responsible for renewing and reloading the certificate before it expires.

Once issued, supply the resulting certificate and key the same way as "your own certificate" above.

### Names your certificate must cover

Four names, derived from your deployment's main domain and service domain. The installer asks for the service domain; by default it is the same as the main hostname. A wildcard is not enough, because a wildcard covers exactly one label and does not match a multi-label name like `push.services.example.com`.

| Name                              | Serves                                                     |
| --------------------------------- | ---------------------------------------------------------- |
| Main domain                       | Vault, Admin Console, the API, and push for modern clients |
| `connect.<service domain>`        | PAM tunnels and connections                                |
| `push.services.<service domain>`  | Server-supplied legacy socket URLs                         |
| `files.services.<service domain>` | File and attachment storage                                |

{% hint style="danger" %}
A missing certificate name adversly impacts product functionality. Ensure all four (4) names are assigned.
{% endhint %}

### Verify

Run `./smk doctor` after installing or after changing the certificate, and whenever something that looks unrelated (a stuck login, a broken PAM tunnel) might actually be a certificate problem. It checks the configured certificate against every required name above, and checks that it is a valid end-entity server certificate, that it chains to the configured CA, and that it matches its key.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.keeper.io/keeperpam/self-managed-keeper/self-managed-keeper-overview/installation/tls-certificates.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
