Wildcard SSL for a SaaS With Many Subdomains
Per-customer subdomains make a wildcard certificate attractive. Learn how it works for a SaaS, how to deploy and renew it safely, and when to choose something else.
10 min readUpdated Nov 20, 2026By XPASS Editorial Team

A software-as-a-service product often gives every customer an address of their own: acme.example.com, northwind.example.com, and so on. Signups happen at any hour, and the list of names grows without anyone planning it. Ordering a certificate for each new name by hand is not workable, and it is exactly the situation a wildcard certificate was designed for. One certificate for *.example.com covers every name that has one label in front of your domain, including names that do not exist yet.
That convenience comes with design decisions that matter more for a SaaS than for a small website. The private key is shared by many servers, the certificate is trusted by every customer, and a subdomain chosen by a customer carries your certificate and your reputation. This article explains how wildcard certificates fit a multi-tenant product, how to deploy and renew them safely, where they stop, and what to use for customers who bring their own domain. If you also need to cover several unrelated domains, how multi-domain SSL covers different domain names is a useful companion.
Why subdomains per customer need a different approach
For a conventional site with three or four hostnames, you list them and order a certificate. For a SaaS the list is open-ended and changes whenever someone signs up. Three problems appear if you try to treat each customer as a separate certificate order.
- Speed. A new customer expects the address to work within seconds of signing up. Waiting for a validation and a certificate for each signup delays onboarding.
- Volume. Hundreds or thousands of certificates mean hundreds or thousands of expiry dates, each of which can fail unnoticed.
- Public visibility. Every issued certificate for a publicly trusted authority appears in certificate transparency logs, which can reveal the names of your customers to anyone watching. A wildcard certificate lists only *.example.com, so individual customer names do not appear there.
A wildcard avoids all three. One certificate, one renewal and one line in public logs. The price you pay is the shared key and the dependence on a single renewal.

How the wildcard works for tenants
The certificate contains the name *.example.com, and optionally example.com as an additional name. The asterisk replaces exactly one DNS label, as defined by the way clients interpret certificate names under the X.509 profile (RFC 5280). That gives you the following behaviour:
| Name | Covered by *.example.com? |
|---|---|
| acme.example.com | Yes |
| northwind.example.com | Yes |
| app.example.com | Yes |
| example.com | No, unless listed as an extra name |
| eu.acme.example.com | No, two labels |
| acme.customer-domain.com | No, a different domain |
On the DNS side you point either a wildcard record such as *.example.com or individual records at the entry point of your platform, for example a load balancer or reverse proxy. That entry point presents the wildcard certificate and uses the requested hostname, sent in the TLS handshake as the server name, to route the request to the right tenant. The same certificate serves every tenant, so the routing logic stays in your application, not in the certificate.
Deployment steps
A safe rollout follows a clear order.
- Decide on the exact name pattern. If tenants live at tenant.example.com, a single wildcard suffices. If you want regional or environment layers, such as tenant.eu.example.com, plan for additional wildcards like *.eu.example.com.
- Order a wildcard certificate that includes the bare domain if you also serve example.com over HTTPS. Check the product page for this detail, and read whether a wildcard covers the root domain to avoid surprises.
- Prepare DNS-based validation. Wildcard names are normally validated by publishing a TXT record in your DNS zone. With the ACME protocol (RFC 8555), an automation tool can do this each time. Give the tool narrowly scoped DNS credentials.
- Generate the private key in a controlled place, ideally within your secrets management system or a hardware-backed store, and create the certificate signing request there.
- Install the certificate and the full chain on every component that terminates TLS for tenant names: load balancers, edge proxies and any regional entry points.
- Test with several tenant names, the bare domain, www and a name that should not exist. The last one should still show a valid certificate, with your application returning a clear not-found page rather than a certificate warning.
- Configure monitoring on expiry and on successful renewal, and document who is on call for failures.
Renewal and rotation
Renewal is the most important operational task. A missed renewal turns every tenant address into a warning page at the same moment.
- Automate. Use an ACME client that supports DNS challenges for your DNS provider, and store the credentials in a secrets system.
- Renew early. Do not wait for the last week. Starting thirty days before expiry leaves time to fix problems.
- Distribute safely. If the certificate is stored in one place and fetched by many servers, make the fetch authenticated and logged. Avoid copying key files by hand.
- Rotate keys. Many teams generate a fresh private key at each renewal. This limits the lifetime of any leaked key and makes a forced rotation routine rather than an emergency.
- Rehearse the emergency. Know how you would replace the certificate within an hour if the key leaked. Decide in advance who has the authority and how the new certificate is rolled out.
Customers who bring their own domain
Many SaaS products allow a customer to use app.customer.com instead of customer.example.com. The wildcard does not help here, because the name belongs to a different domain. Options include:
- A separate certificate for each custom domain, issued after the customer points a DNS record at your service so that you can prove control through the standard challenge methods. Automation is essential at any volume.
- A multi-domain certificate that lists several custom domains, which only suits small, stable numbers and has the disadvantages described in the related article on multi-domain SSL.
- A platform or CDN feature that issues and renews certificates for custom domains automatically. If you rely on one, check which validation methods it uses and who holds the private key.
Whichever route you take, tell customers exactly which DNS records they must create, and show clear status messages when validation is pending or fails.
A worked example
A small project-management SaaS runs at example.com. Each customer workspace gets a name, for example acme.example.com. The company runs two load balancers in front of its application servers.
The team orders a wildcard certificate for *.example.com plus example.com. Their DNS provider offers an API, so they set up an ACME client on a small management server. The client publishes the required TXT record, receives the certificate and writes it to a secrets store. The load balancers fetch it from the store through an authenticated request and reload without downtime.
When a new customer signs up, the application checks the requested name against rules: three to thirty characters, lowercase letters, digits and hyphens, no leading or trailing hyphen, and not on the reserved list that includes login, billing, status, support and admin. The record is created, and acme.example.com works at once with a valid certificate because the wildcard already covers it.
A large customer asks to use app.acme-corp.com. The team does not touch the wildcard. They ask the customer to add a CNAME record pointing to a name controlled by the platform, then request a separate certificate for that name through the ACME process and attach it to the load balancer's configuration. Renewal for that name is handled by the same automation.
Six months later, a certificate monitoring check reports that the wildcard has thirty days left and that the last renewal attempt failed because the DNS API token expired. Because monitoring exists, the team replaces the token, retries the renewal and confirms success with plenty of time to spare.
Limits and what to watch for
- One label only. The wildcard does not cover tenant.region.example.com. Plan names accordingly, or add wildcards for each region.
- Shared key. Anyone who obtains the private key can impersonate every name under the wildcard. Restrict access, log it and design for fast replacement.
- Name abuse. If customers choose subdomains freely, someone could pick a name that imitates a bank or a sensitive service, and it would appear under your certificate. Reserve names, restrict characters and add a review process for suspicious choices.
- Cookie and security boundaries. Subdomains of the same domain can share cookies if you set them for the parent domain. Keep session cookies host-only unless you have a specific need, and consider hosting untrusted customer content on a separate domain entirely.
- Dependence on DNS access. Automated renewal requires the tool to edit DNS. Limit its permissions to the required zone and record type where your provider allows it.
- Clients with pinned certificates. If customers pin your certificate in integrations, changes will break them. Document your renewal practice and give notice for key changes.
- Not a measure of trust. A valid certificate proves the connection is encrypted and the name matches. It says nothing about who runs the tenant's content.
A tenant onboarding checklist
A short checklist keeps the process predictable as the product grows. Review it whenever you change the platform.
- Name rules are enforced in code, not only in documentation. The same rules apply in the signup form, the API and the admin tools.
- A reserved list blocks names that could mislead visitors or collide with your own services, such as login, billing, status, mail, support and admin. Update the list whenever you launch a new service under the domain.
- The wildcard DNS record, or the individual record, exists before the name is shown to the customer, so the address works the first time it is opened.
- A request for an unknown tenant name returns a clear not-found page over a valid HTTPS connection, not a certificate warning.
- Logs record which name was requested, so support can answer questions such as "why does my workspace address not load".
- Offboarding removes the DNS record or disables the tenant, and the name is held for a period before it can be reused, so a new customer cannot inherit stale links or cached sessions from a former one.
- Certificate expiry, renewal success and DNS credential expiry all have monitors with alerts that reach a person, not only a shared mailbox nobody reads.
Teams that adopt these habits early spend far less time on emergencies later, and the customer experience is steadier because the address simply works.
Wildcard or per-subdomain certificates
Not every SaaS should use a wildcard. A wildcard is convenient, but a certificate per subdomain isolates risk and reveals individual names in public logs. The right choice depends on tenant volume, sensitivity and how fast onboarding must be. The comparison in one certificate versus an SSL certificate for each subdomain goes through those trade-offs in depth. As a rough guide, products with many small tenants and open-ended signup lean toward a wildcard, while products with a few large, high-sensitivity tenants may prefer separate certificates.
Questions to ask a provider
Before ordering, ask whether the wildcard includes the bare domain, which validation methods are supported for wildcard names, whether the certificate can be reissued with a fresh key at any time, how renewal can be automated and what the support process is if validation fails. The details are on the SSL page, where you can compare certificate types.
Summary
A wildcard certificate for *.example.com lets a SaaS give every customer a working HTTPS subdomain without ordering a certificate per signup. It keeps customer names out of public logs and reduces the number of renewals to one. The costs are a shared private key, validation through DNS, coverage of only one label and no help for customers who bring their own domain. Automate renewal, reserve sensitive names, store the key carefully and use separate certificates for custom domains. To check how the apex is handled, read whether a wildcard covers the root domain.
When you are ready to compare certificate types, the SSL page shows what each one includes.
Frequently asked questions
Why is a wildcard certificate popular with SaaS products?
When each customer gets a name such as acme.example.com, new names appear without notice. A wildcard for *.example.com covers every new single-label name automatically, so you do not need to order a certificate for each signup.
Does a wildcard work for customers who use their own domain?
No. A wildcard covers subdomains of your domain only. A customer's own domain, such as app.customer.com, needs a certificate that lists that name, usually obtained and renewed automatically per domain.
Is a shared private key a problem for a SaaS?
It raises the stakes. Every server that terminates HTTPS for customer subdomains holds the same key, so keep it in a secrets system, limit access and design the rollout so that a key can be replaced quickly.
Can customers choose any subdomain name they like?
Only if you validate the choice. Reserve sensitive names such as login or billing, restrict the characters, and review names that could mislead visitors, because every name under the wildcard carries your certificate.
How should a SaaS renew a wildcard certificate?
Automate it. Wildcard issuance normally needs a DNS challenge, which an ACME client can complete by publishing a TXT record. Monitor the expiry date and test the renewal path before the deadline.
References
About the author

Bob Kanokphon Thongdee
- Founder of XPASS VPN
- Co-founder of eSIMonline.asia
- More than 7 years in online marketing
- Founder of Cojourney Visa and Cojourney Travel
Need an SSL certificate?
Pick the certificate type that fits your site and see the price before you check out.
SSL from $14.99
See SSL certificatesKeep reading

SSL Guides
How a Multi-Domain SSL Certificate Covers Different Domain Names
A multi-domain certificate lists several unrelated names in one file. Learn how the SAN list works, how each name is validated, and when it beats separate certificates.
10 min read

SSL Guides
One Certificate or a Separate SSL Certificate per Subdomain?
Covering all subdomains with one certificate is tidy, but a separate certificate per subdomain limits the damage when something goes wrong. Here is how to choose.
10 min read

SSL Guides
Does a Wildcard SSL Certificate Cover the Root Domain?
A wildcard matches one label in front of your domain, so the bare domain is a separate case. See how matching works and how to make sure example.com is covered.
9 min read