Skip to content
Agentic AI Builder's Guide

Search every lesson, prompt, glossary term and troubleshooting topic. Use ↑ ↓ to move and Enter to open.

Module 5 of 6

Production Launch

Public URLs, domains, DNS records, HTTPS, propagation, auth callbacks, smoke testing, rollback and a complete launch checklist.

Full printable guide

0% · 0 of 13 lessons

Your application is deployed. Now you will make it publicly reachable, connect a custom domain, secure it with HTTPS, and validate it thoroughly before real users arrive.

Generating a public Railway URL

New services are not always publicly reachable by default. To create a public address:

  1. Open the application service and go to its Settings → Networking area (or equivalent).
  2. Choose Generate Domain.
  3. Railway assigns a URL ending in .up.railway.app with HTTPS already configured.
  4. Open it and confirm the application loads.

Update any variable that holds your application's public URL (for example APP_URL) so links, emails and authentication redirects use the correct address.

Domain registration fundamentals

A domain name such as example.com is rented annually from a domain registrar. Key concepts:

  • Registrar: the company you pay for the domain.
  • DNS provider: the service that answers DNS queries for your domain. Often the same as the registrar, but it can be a separate service.
  • Nameservers: tell the internet which DNS provider is authoritative for your domain.
  • Renewal: domains expire if not renewed. Enable auto-renew and keep billing details current.

When choosing a domain, prefer short, easy-to-spell names. Check renewal prices, not only first-year promotional prices.

Custom domains and subdomains

  • Apex (root) domain: example.com
  • Subdomain: app.example.com, www.example.com

Subdomains are the simplest to connect because they use a standard CNAME record. Connecting an apex domain requires a DNS provider that supports CNAME-like records at the root (CNAME flattening or ALIAS records). Railway's documentation notes that some providers lack this; the options are to move DNS management (nameservers) to a provider that supports it, or to use www or another subdomain and redirect the apex domain to it.

DNS record types

TypePurposeExample
APoints a name to an IPv4 addressexample.com → 203.0.113.10
AAAAPoints a name to an IPv6 addressexample.com → 2001:db8::1
CNAMEPoints a name to another hostnameapp → example-value.up.railway.app
TXTHolds text, often for ownership verificationDomain verification tokens
MXRoutes email for the domainYour email provider's servers
NSDelegates the domain to nameserversYour DNS provider

Values above are illustrative documentation examples.

Configuring DNS using Railway-provided values

DNS and custom domain configuration

1. Railway networking

Add custom domain, copy the record type, name and value

2. DNS provider

Create the records. Keep unrelated records.

3. Verification + HTTPS

Railway verifies and issues a certificate

4. Users

https://app.example.com reaches your service
TypeNameValue (illustrative)
CNAMEappexample-value.up.railway.app
TXTverification name from Railwayverification value from Railway
Railway gives you the DNS record values. You create those records at your DNS provider. Once DNS resolves to Railway and verification succeeds, Railway provisions the HTTPS certificate. Values shown are illustrative only.
  1. In the application service's networking settings, choose to add a Custom Domain.
  2. Enter the domain or subdomain, for example app.example.com.
  3. Railway displays the DNS records you must create, each with a type, a name (host) and a value. Expect a CNAME record that points your domain at Railway and a TXT record that proves you own the domain. Both are required — without the verification record, requests to the domain fail.
  4. Copy these values exactly. Use the values Railway shows you, not examples from this or any other guide.
  5. Log in to your DNS provider and open the DNS management page for the domain.
  6. Create each record with the exact type, name and value.
  7. Return to Railway and wait for the domain to show as verified or active.

Entering the name correctly

DNS providers handle the name field differently. For app.example.com, most providers expect just app; some expect the full name. Entering app.example.com where the provider appends the domain automatically produces app.example.com.example.com. Check your provider's help pages if unsure.

HTTPS

HTTPS encrypts traffic between users and your application using a TLS certificate. Railway provisions and renews certificates automatically for Railway domains and for custom domains once DNS is correctly configured.

  • Certificate issuance can take a little time after DNS verification.
  • If the browser shows a certificate warning, wait and retry before changing settings; then check that DNS records match Railway's values exactly.
  • Railway issues certificates from Let's Encrypt automatically and renews them before they expire. Issuance usually completes within about an hour of DNS updating.
  • If your DNS provider proxies traffic (for example, Cloudflare's proxied "orange cloud" mode), Railway's documentation requires the SSL/TLS mode to be Full, not Full (Strict). Proxies can also interfere with verification; follow Railway's current guidance.

DNS propagation

DNS records are cached by resolvers around the world for a period defined by their TTL (time to live). After a change, some users may see the old answer until caches expire. This is called propagation.

  • Often minutes; Railway's documentation notes DNS changes can take up to 72 hours.
  • Lowering the TTL in advance helps future changes propagate faster.
  • Check from the terminal:
bash
dig app.example.com CNAME +short
nslookup app.example.com

Online DNS lookup tools can show results from several locations.

Authentication callback URLs

If your application uses sign-in with Google, GitHub, Microsoft or an authentication service, each provider requires a list of allowed callback (redirect) URLs. Sign-in fails if the production URL is missing.

After connecting a domain:

0 of 4 complete

Production smoke testing

A smoke test is a quick check that the most important things work after deployment. Run it after every production release.

0 of 7 complete

Launch readiness

Before announcing your application, run a one-time readiness review with Claude Code, then validate the results yourself.

Claude CodeQuality

Production Readiness Validation

Purpose
Have Claude Code perform a focused, one-time pre-launch review and fix material issues.
When to use
Once, before announcing a public launch or connecting a custom domain for real users.
Replace these placeholders: [PRODUCTION URL][AUTHENTICATION PROVIDER, if any][KNOWN CONCERNS]
# Production readiness validation

## Operating instructions
Use LOW GAS throughout this task.
Minimize token consumption, unnecessary analysis, repetitive audits, readiness checks and intermediate reports. Consolidate related implementation activities. Do not create additional planning phases or request approval for routine implementation decisions.
Run essential tests, type checking and production builds. Do not compromise security or functionality to reduce model usage.
Perform this review once. Do not repeat audits.

## Context
The application is deployed at [PRODUCTION URL]. Authentication: [AUTHENTICATION PROVIDER, if any]. Known concerns: [KNOWN CONCERNS].

## Review and fix material issues in these areas
1. Secrets: no credentials in source code, git history of tracked files, logs or client bundles. .env files are git-ignored. .env.example contains placeholders only.
2. Authentication and authorization: protected routes and APIs reject unauthenticated or unauthorized requests. Callback URLs are configured for the production domain.
3. Input validation and error handling: server-side validation, no stack traces or internal errors shown to users, consistent error pages.
4. Configuration: the app listens on the PORT environment variable, production settings are used, a health check endpoint exists where appropriate.
5. Database: migrations are repeatable, connection uses environment variables, failures are handled gracefully.
6. Dependencies: no known critical vulnerabilities in direct dependencies (run the package manager audit and fix only what is safe).
7. Basic security headers and HTTPS-only assumptions where applicable.
8. Mobile usability of the core workflows.

## Rules
Fix material issues directly. List anything that requires a human decision or manual action instead of guessing. Run tests, type checking and the production build. Commit and push to main without force-pushing.

## Completion report
Findings grouped as fixed, requires manual action, and accepted risk. Include results and commit hash.

Rollback planning

A rollback returns production to the last known-good version. Decide in advance how you will do it:

  • Railway deployment history: previous deployments are listed on the service, and you can redeploy or roll back to an earlier one from there.
  • Git revert: create a new commit that undoes a faulty change, then push: git revert COMMIT_HASH and git push. This preserves history, unlike a force-push.
  • Database changes: code rollbacks do not undo migrations. Prefer backward-compatible migrations (add columns before removing old ones) so older code still works.

Backup and recovery

  • Understand what backup options your Railway database service offers and enable them where available.
  • For critical data, also take periodic exports you control, for example with pg_dump for PostgreSQL.
  • Store backups securely; they contain your users' data.
  • Test a restore into a separate database. A backup you have never restored is unproven.
  • Document the recovery steps in your repository (without credentials).
bash
# Illustrative PostgreSQL export using a connection string from a secure variable
pg_dump "$DATABASE_URL" --format=custom --file=backup-$(date +%Y%m%d).dump

Production launch checklist

Code and configuration

0 of 6 complete

Data

0 of 3 complete

Domain and security

0 of 7 complete

Operations

0 of 5 complete