Create a self-signed SSL certificate for local development: host names and IPs that browsers accept, key and .p12 downloads, and server settings.
Initializing in your browser…
Generate a certificate signing request and private key in your browser, with SANs and RSA or ECDSA keys, checked before you send it to a CA.
Decode any SSL/TLS certificate in your browser: issuer, dates, host names and extensions in plain words, with host checks and chain verification.
Check a site's SSL certificate chain for a missing intermediate, wrong order, expiry or name mismatch, with the OpenSSL commands to fetch it.
You need HTTPS on a local development server at app.example.test, including its subdomains and plain localhost.
Form
Common name app.example.test Other names *.app.example.test, localhost, 127.0.0.1 Key RSA 2048, SHA-256 Valid for 365 days
openssl x509 -in app.example.test.crt -noout -subject -dates -ext ...
subject=CN=app.example.test
notBefore=Oct 21 08:00:00 2026 GMT
notAfter=Oct 21 09:00:00 2027 GMT
X509v3 Basic Constraints: critical
CA:FALSE
X509v3 Key Usage: critical
Digital Signature, Key Encipherment
X509v3 Extended Key Usage:
TLS Web Server Authentication, TLS Web Client Authentication
X509v3 Subject Alternative Name:
DNS:app.example.test, DNS:*.app.example.test, DNS:localhost, IP Address:127.0.0.1Made at 09:00 UTC on 21 October 2026, the certificate is valid from an hour earlier, so a slightly slow clock still accepts it, until the same time a year later. The common name is the first entry in the Subject Alternative Name, which is the list browsers actually check, followed by the wildcard (covering api.app.example.test and any other single-level subdomain), localhost and the IPv4 loopback address. The files download as app.example.test.crt and app.example.test.key.
Make an SSL/TLS certificate for local development in a few seconds: enter the host name, list any other names and IP addresses, and download the certificate and private key, or a .p12 bundle. Ready-to-paste settings for nginx, Apache and Node.js are included, and everything is generated in your browser.
Why a self-signed certificate. Some features only work over HTTPS, such as secure cookies, service workers on a custom host name, or calling an API that refuses plain HTTP. For a development machine, a test server or an internal tool, a certificate you sign yourself is the quickest way to get there. No certificate authority is involved, so nobody else trusts it automatically: you add it to your own system or browser trust store once.
Names that browsers accept. Browsers check the host name against the Subject Alternative Name list only, never the common name. The generator puts the common name into that list when it is a host name, and you can add more: localhost, 127.0.0.1, ::1, other host names and wildcards such as *.app.example.test, which covers one level of subdomains. Each name is checked as you type, so a typo or a space is caught before the certificate is made, and the chips show exactly what will be included.
Key, hash and lifetime. RSA 2048 is quick to generate and accepted everywhere; 3072 and 4096 take longer. SHA-256 is the right signature hash for almost every use. Keep the lifetime at 825 days or less for server certificates, because Apple devices refuse longer ones. The certificate is valid from an hour before it is made, so a clock running slightly behind does not reject it.
A private certificate authority. Turn on the CA option to make a root certificate instead. Add it to your trust store once, then use it to sign server certificates with OpenSSL, so every development certificate it signs is trusted without adding each one.
Files you get. The certificate (.crt), the private key in PKCS #8 or the older PKCS #1 form, the public key, and a password-protected .p12 bundle for Windows, macOS Keychain and Java. A wildcard name is written as wildcard in file names, so the commands work in any shell.
Keep the defaults: the certificate covers localhost, 127.0.0.1 and ::1. Trust it once and your local server works over https://localhost.
Use app.example.test as the common name and add *.app.example.test, so api.app.example.test and admin.app.example.test are covered too.
Turn on the CA option, name it something like Team Dev Root, and share the certificate (never the key) for everyone to trust. Server certificates signed with it are then trusted on every machine.
A self-signed certificate is not vouched for by any authority your system knows. Add it to your operating system or browser trust store, and make sure the host name you visit is in its list of names.
On macOS, open it in Keychain Access, add it to the System keychain and set it to Always Trust. On Windows, import it into Trusted Root Certification Authorities. On Linux, copy it to the system CA folder and run the update command for your distribution. Firefox may need it added in its own settings.
The key is made by the page in your browser and never uploaded. Treat it like any key: keep it out of source control and do not reuse a development key in production.
PKCS #8 (BEGIN PRIVATE KEY) works with most current software, including Node.js, Java and Go. PKCS #1 (BEGIN RSA PRIVATE KEY) is the older OpenSSL form that nginx and Apache also accept. Both are the same key.
It protects the bundle file. Windows, macOS and Java ask for it on import. The default, changeit, is the usual Java keystore password; set your own if the file will be shared.
A year is a good default. Apple devices refuse server certificates valid for more than 825 days, even self-signed ones you trust, so stay under that.
This runs as client-side JavaScript. Keys, tokens, payloads, and other inputs never leave your device.