Security

What Is a CSR and How Do I Generate One? SSL Guide

16 min read November 15, 2026 By zasma171
What is a CSR and how to generate one for an SSL certificate

What is a CSR? It is a certificate signing request that connects your domain details to a public key. This guide covers three easy ways to create one safely.

What is a CSR and how to generate one for an SSL certificate
What is a CSR and how to generate one for an SSL certificate

Quick answer: A CSR (Certificate Signing Request) is an encoded block of text containing your domain name, organization details and public key, which you send to a Certificate Authority to get an SSL certificate. You generate it on your server with a matching private key, using cPanel’s SSL/TLS tool, OpenSSL, or IIS Manager.

Almost every SSL certificate order starts with the same request: “paste your request here.” For many site owners, that is the first time they have heard the term. The good news is that a CSR is easy to create once you know what it contains and where to generate it. This guide explains what a CSR is, what each field means, and exactly how to generate one in cPanel, with OpenSSL, and on Windows IIS, plus the mistakes that force a reissue.

Key Takeaways

  • A CSR carries your public key and certificate details; the private key stays secret on your server.
  • The Common Name or SAN must exactly match the domain you want to secure.
  • You can generate a CSR in cPanel, with OpenSSL on Linux or macOS, or in IIS Manager on Windows.
  • Use at least a 2048-bit RSA key or an ECDSA P-256 key.
  • Lose the private key and the certificate is useless, so back it up securely.

What Is a CSR in SSL?

A CSR, or Certificate Signing Request, is a standardized message you send to a Certificate Authority (CA) asking it to issue a certificate for your public key and domain.

The CSR follows the PKCS #10 format and is usually delivered as Base64 text that starts with —–BEGIN CERTIFICATE REQUEST—– and ends with —–END CERTIFICATE REQUEST—–. Inside it are three things:

  • Your public key, which will be embedded in the issued certificate.
  • Identifying information, such as the domain name and, for OV or EV certificates, your organization details.
  • A signature made with your private key, which proves you hold the key that matches the public key in the request.

The CA checks the request, validates your domain and, where needed, your organization, and then signs a certificate that contains your public key. The private key never leaves your server.

What Is a CSR Required to Contain?

The request contains your domain name and, optionally, organization and location fields, plus the public key and key algorithm.

Field Example Notes
Common Name (CN) www.example.com The main hostname; use *.example.com for a wildcard
Subject Alternative Names (SAN) example.com, shop.example.com Extra hostnames; often added in the order form
Organization (O) Example Company LLC Exact legal name for OV and EV; optional for DV
Locality (L) Austin City where the organization is registered
State or Province (ST) Texas Write it in full, not abbreviated
Country (C) US Two-letter ISO country code
Key algorithm and size RSA 2048 or ECDSA P-256 Set when generating the key pair

For Domain Validated certificates, the CA only uses the domain names, so the other fields matter less. For OV and EV, the organization details must match official records exactly, or validation will stall. The Organizational Unit (OU) field is no longer included in publicly trusted certificates, so you can leave it blank.

What Is a CSR in cPanel?

In cPanel, open SSL/TLS, choose “Generate, view, or delete SSL certificate signing requests,” fill in the form, and copy the request text.

  1. Log in to cPanel and open the SSL/TLS tool in the Security section.
  2. Under Certificate Signing Requests, click Generate, view, or delete SSL certificate signing requests.
  3. Choose an existing private key or let cPanel generate a new one (RSA 2048-bit or higher, or ECDSA).
  4. Enter the domains, city, state, country and company name. Include both example.com and www.example.com if you need them.
  5. Click Generate. cPanel shows the encoded CSR and stores the private key in the Private Keys section.
  6. Copy the entire CSR, including the BEGIN and END lines, and paste it into your SSL order.

Because cPanel keeps the private key for you, installation later is simple: paste the issued certificate into the SSL/TLS manager and cPanel matches it with the stored key. Plans like Kawedma WordPress hosting include cPanel, so this is the easiest route for most site owners.

Ready to secure your site? Have your request ready and complete your SSL order in minutes. Browse SSL certificates at Kawedma.

How Do You Generate a CSR With OpenSSL?

Run a single OpenSSL command that creates a new private key and a CSR, answer the prompts, and keep the key file safe.

On Linux, macOS or a VPS, OpenSSL is usually already installed. A typical command is:

openssl req -new -newkey rsa:2048 -nodes -keyout example.com.key -out example.com.csr

  1. -newkey rsa:2048 creates a new 2048-bit RSA key pair. Use rsa:3072 or an EC key if you prefer.
  2. -nodes stores the key without a passphrase so the web server can start without manual input. Protect the file with strict permissions instead.
  3. -keyout names the private key file, and -out names the request file.
  4. Answer the prompts for country, state, locality, organization and Common Name.
  5. Open the .csr file in a text editor and copy its contents into your order.

To include extra hostnames directly in the request, newer OpenSSL versions support an -addext option such as subjectAltName=DNS:example.com,DNS:www.example.com. Many providers also let you add SANs in the order form instead.

What Is a CSR on Windows IIS?

In IIS Manager, open Server Certificates, choose “Create Certificate Request,” enter your details, choose the key length, and save the request to a text file.

  1. Open Internet Information Services (IIS) Manager and select the server name.
  2. Double-click Server Certificates, then click Create Certificate Request in the Actions pane.
  3. Enter the Common Name, organization, city, state and country.
  4. Select the Microsoft RSA SChannel Cryptographic Provider and a bit length of 2048 or higher.
  5. Save the request as a .txt file and paste its contents into your SSL order.

IIS stores the pending private key on that server. Complete the request on the same machine when the certificate is issued, and export a PFX backup afterward.

What Is a CSR Error and How Can You Avoid It?

Most request problems come from a wrong domain name, mismatched organization details, a weak key, or a lost private key.

Mistake Result How to avoid it
Typo in the Common Name Certificate issued for the wrong hostname Copy the domain carefully and double-check before submitting
Organization name not matching legal records OV or EV validation delays Use the exact registered legal name
Abbreviated state name Validation queries from the CA Spell the state or province in full
Key shorter than 2048-bit RSA CA rejects the request Use RSA 2048 or higher, or ECDSA P-256
Private key deleted or lost Issued certificate cannot be installed Back up the key securely, or reissue with a new CSR
Partial copy of the request Order form reports invalid CSR Include the BEGIN and END lines and all text between

Before submitting, you can decode the request with an online CSR decoder or with openssl req -text -noout -verify -in example.com.csr to confirm every field is correct.

Do You Need a New CSR for Every Renewal?

Not always, but generating a fresh CSR and private key at each renewal or reissue is the recommended practice.

Some providers allow reusing an old request, which reuses the same key pair. That works, but it means the same private key protects your site for longer, increasing the impact if it was ever exposed. Creating a new key pair is quick, especially in cPanel or with automated ACME clients, which generate new keys automatically.

You must create a new CSR when you change the domain names, switch key algorithms, move to a new server without the old key, or suspect the private key may have been compromised. With certificate lifetimes getting shorter, generating a new CSR becomes a routine part of each renewal.

Frequently Asked Questions

Does the request contain my private key?

No. The CSR contains your public key and certificate details and is safe to share with a Certificate Authority. The private key is generated alongside it and must stay secret on your server. The issued certificate only works together with the private key that matches the request, so both files are important.

What happens if I lose the private key after submitting my CSR?

The issued certificate will not work, because it can only be installed with the matching private key. The fix is to generate a new private key and CSR, then request a reissue under your SSL provider’s policy. Validation for DV is quick, and OV or EV details can often be reused.

Are online key generators safe?

Some websites offer online CSR generators, but they create your private key on someone else’s system, which is a security risk. It is safer to generate the request and key on your own server, in your hosting control panel such as cPanel, or with OpenSSL on a trusted computer that you control.

Which key algorithm and size should I use?

Use an RSA key of at least 2048 bits, which is the minimum accepted by public Certificate Authorities, or an ECDSA key on the P-256 curve. ECDSA keys are smaller and faster while offering strong security. RSA 3072 or 4096 is also accepted but adds some processing overhead during TLS handshakes.

How can I inspect the encoded request?

Paste the request into an online CSR decoder or run openssl req -text -noout -verify -in yourfile.csr. Both show the Common Name, organization fields, key size and any Subject Alternative Names, so you can catch typos before ordering. The CSR contains no secret data, so decoding it is safe.

Order Your SSL Certificate Today at Kawedma

A correct CSR is the first step to a smooth SSL order. Generate it on your own server, keep the private key safe, and double-check the domain and organization details before you submit. Kawedma’s SSL certificates accept CSRs from cPanel, OpenSSL and IIS, with reissues available when you need them. Order your SSL certificate at Kawedma and explore domains and hosting at kawedma.com.

Official Command Reference

Check the OpenSSL req documentation for supported request options. In current OpenSSL releases, -noenc replaces the deprecated -nodes option. Protect any unencrypted private key with restrictive file permissions.

What Is a CSR Generation Environment?

Generate the key pair on the system where you will install the certificate, or on a trusted administrator workstation that can transfer the key securely. Do not use a public computer. Decide who owns the certificate, who can access the private key, and where the recovery copy will be stored. A request is easy to replace; an exposed private key requires immediate attention.

If a colleague asks, “what is a CSR used for during deployment?”, explain the boundary clearly: the request travels to the certificate provider, while the private key stays under your control. Sending the request does not complete installation, enable HTTPS, or prove that you own the domain. Those are separate steps in the issuance and deployment process.

What is a CSR file compared with CRT and PFX?

The file extension describes a common convention rather than a security guarantee. A .csr file normally contains the signing request. A .crt or .cer file normally contains the issued certificate. A .key file normally contains the private key. A .pfx or .p12 bundle can contain both the certificate and its private key, so treat that bundle as sensitive and protect its export password.

Keep a simple inventory with the hostname, certificate provider, server name, renewal contact, and storage location. Record the key location without copying the actual key into tickets, spreadsheets, or chat. When several administrators share responsibility, this inventory prevents a certificate from being installed on the wrong server or renewed by someone who cannot access the matching key.

What is a CSR hostname checklist?

List every hostname the application actually serves before placing the order. The root domain, www hostname, and an application subdomain are different names. A wildcard such as *.example.com normally covers one subdomain level; it does not automatically cover the root domain or a deeper name such as api.shop.example.com. Confirm the certificate product and the requested Subject Alternative Names with your provider.

For a small shop, that list might include example.com, www.example.com, and checkout.example.com. Test which names redirect and which directly serve HTTPS. A redirect from an HTTPS address still needs a valid certificate for the address that receives the initial connection. The browser checks the certificate before it follows the redirect.

What is a CSR validation step before ordering?

Inspect the request locally and compare its hostnames with your inventory. Check the key algorithm and size, review organization spelling if the certificate requires business validation, and verify the request signature. Never paste a private key into a request decoder. A private key block and a certificate request block have different BEGIN and END labels; read those labels before copying anything.

Domain validation may require a DNS record, an HTTP file, or another supported method. Use the method shown by your certificate authority and retain the exact record or file contents until validation completes. A correctly generated request cannot compensate for an incorrect DNS zone, an inaccessible validation file, or a domain you cannot control.

Install the SSL certificate after generating and validating the request

What is a CSR installation handoff?

After issuance, install the certificate with its matching private key and the intermediate chain supplied or recommended by the provider. Follow the web server or control panel instructions for your platform. Then test every hostname from a browser and inspect the certificate dates and names. An issued certificate sitting in a downloads folder does not secure a running website.

When another team handles installation, send the certificate and chain through your normal approved channel and identify the destination server. If the private key must move, use a secure transfer method with restricted access. Do not include the key in a public support ticket. Remove temporary copies after the transfer and confirm that the recovery backup remains available to authorized administrators.

Avoid certificate request and SSL installation mistakes

What is a CSR recovery plan after a mistake?

If you lose the matching private key, create a new key pair and request a replacement certificate from your provider. Reissue availability, validation requirements, and charges depend on the certificate product and provider policy. If the key was exposed, follow the provider’s revocation process as well; simply generating another request does not invalidate the old certificate.

For a typo in a hostname, correct the order through the provider’s supported replacement process. For a missing hostname, check whether the product allows that additional name. For a server migration, confirm whether you will securely transfer an existing key or issue a new certificate with a fresh key. Test the destination before changing live traffic.

Monitor SSL expiration and prepare certificate renewal

What is a CSR renewal responsibility checklist?

Assign a primary owner and a backup contact. Monitor certificate expiration independently of the renewal invoice, because payment, issuance, installation, and the live certificate can become out of sync. Document any DNS or hosting access required for validation. Before a renewal window, verify that the responsible team still has access to the server and the certificate account.

Finally, rehearse the whole process on a noncritical hostname when possible. Generate the request, inspect it, complete validation, install the certificate, and check the live result. This turns the answer to “what is a CSR?” into a repeatable operational process rather than a last-minute copying exercise during an outage.

What Is a CSR Deployment Workflow?

Imagine you run a small business site on a server managed by two people. The site already has a certificate, but its private key is stored on an older machine that will soon be retired. Your goal is to replace that dependency without interrupting visitors. Start by recording the live hostnames and the current certificate expiration date. Keep the existing working deployment available while preparing the replacement.

On the destination server, generate a fresh key pair and request using the selected method. Give the files clear names and restrict the key to the service account or administrators who need it. Inspect the request locally. Compare every requested name with the hostname list rather than relying on memory. Keep the request and the key together in your inventory, but apply different access rules to them.

Next, submit the request to the certificate provider and complete the validation steps shown in your order. If the provider asks for a DNS record, identify the authoritative DNS service before adding anything. A record entered at a registrar that no longer hosts your DNS will not help validation. Ask the DNS administrator to confirm the change rather than repeatedly creating new orders.

When the certificate arrives, install it on the destination with the corresponding key and intermediate chain. Check the application and all hostnames before directing visitors there. If a load balancer or CDN terminates TLS, include that component in the plan. The browser-facing certificate and the origin-server certificate may serve different connections and have separate renewal responsibilities.

Record the successful test and the installed certificate details. Remove abandoned request files and temporary key copies according to your team’s policy, while retaining the approved recovery backup. Confirm that monitoring checks the live endpoint. A renewal reminder from the provider is useful, but an independent check catches installation mistakes or a certificate served by the wrong virtual host.

Questions to Ask Before Handing Work to Support

  • Which exact hostnames need to be covered, including any www or application subdomains?
  • Where will TLS terminate: the web server, a reverse proxy, a load balancer, or a CDN?
  • Who generates and retains the private key, and who is authorized to install the issued certificate?
  • Which domain validation method will be used, and who can make the required change?
  • How will you test the live result and monitor its expiration after the order is complete?

For a business owner who wants help choosing a certificate product, KAWEDMA’s SSL certificate service is the relevant starting point. Review the product’s hostname coverage, validation level, renewal terms, and available support before ordering. Keep the private key out of the sales conversation: choosing a service does not require publishing or emailing that secret.

zasma171

Contributor at the Kawedma blog.

Leave a comment

Your email address will not be published. Required fields are marked *