Skip Navigation
Show nav
Dev Center
  • Get Started
  • Documentation
  • Changelog
  • Search
  • Get Started
    • Node.js
    • Ruby on Rails
    • Ruby
    • Python
    • Java
    • PHP
    • Go
    • Scala
    • Clojure
    • .NET
  • Documentation
  • Changelog
  • More
    Additional Resources
    • Home
    • Elements
    • Products
    • Pricing
    • Careers
    • Help
    • Status
    • Events
    • Podcasts
    • Compliance Center
    Heroku Blog

    Heroku Blog

    Find out what's new with Heroku on our blog.

    Visit Blog
  • Log inorSign up
Hide categories

Categories

  • Heroku Architecture
    • Compute (Dynos)
      • Dyno Management
      • Dyno Concepts
      • Dyno Behavior
      • Dyno Reference
      • Dyno Troubleshooting
    • Stacks (operating system images)
    • Networking & DNS
    • Platform Policies
    • Platform Principles
  • Developer Tools
    • Command Line
    • Heroku VS Code Extension
  • Deployment
    • Deploying with Git
    • Deploying with Docker
    • Deployment Integrations
  • Continuous Delivery & Integration (Heroku Flow)
    • Continuous Integration
  • Language Support
    • Node.js
      • Troubleshooting Node.js Apps
      • Working with Node.js
      • Node.js Behavior in Heroku
    • Ruby
      • Rails Support
      • Working with Bundler
      • Working with Ruby
      • Ruby Behavior in Heroku
      • Troubleshooting Ruby Apps
    • Python
      • Working with Python
      • Background Jobs in Python
      • Python Behavior in Heroku
      • Working with Django
    • Java
      • Java Behavior in Heroku
      • Working with Java
      • Working with Maven
      • Working with Spring Boot
      • Troubleshooting Java Apps
    • PHP
      • Working with PHP
      • PHP Behavior in Heroku
    • Go
      • Go Dependency Management
    • Scala
    • Clojure
    • .NET
      • Working with .NET
  • Databases & Data Management
    • Heroku Postgres
      • Postgres Basics
      • Postgres Getting Started
      • Postgres Performance
      • Postgres Data Transfer & Preservation
      • Postgres Availability
      • Postgres Special Topics
      • Migrating to Heroku Postgres
    • Heroku Key-Value Store
    • Apache Kafka on Heroku
    • Other Data Stores
  • AI
    • Working with AI
    • Heroku Inference
      • Inference API
      • Quick Start Guides
      • Inference Essentials
      • AI Models
    • Vector Database
    • Model Context Protocol
  • Monitoring & Metrics
    • Logging
  • App Performance
  • Add-ons
    • All Add-ons
  • Collaboration
  • Security
    • App Security
    • Identities & Authentication
      • Single Sign-on (SSO)
    • Private Spaces
      • Infrastructure Networking
    • Compliance
  • Heroku Enterprise
    • Enterprise Accounts
    • Enterprise Teams
    • Heroku Connect (Salesforce sync)
      • Heroku Connect Administration
      • Heroku Connect Reference
      • Heroku Connect Troubleshooting
  • Patterns & Best Practices
  • Extending Heroku
    • Platform API
    • App Webhooks
    • Heroku Labs
    • Building Add-ons
      • Add-on Development Tasks
      • Add-on APIs
      • Add-on Guidelines & Requirements
    • Building CLI Plugins
    • Developing Buildpacks
    • Dev Center
  • Accounts & Billing
  • Troubleshooting & Support
  • Integrating with Salesforce
  • Security
  • App Security
  • Heroku App Names, Subdomains, and URLs

Heroku App Names, Subdomains, and URLs

English — 日本語に切り替える

Last updated March 12, 2025

Table of Contents

  • App Names
  • Subdomains
  • URLs

Every Heroku app has a unique app name and subdomain. This article explains how they’re generated and the relationship between them.

App Names

The app name is a unique identifier for your application. It can be a string of lowercase letters, numbers, and dashes, up to 30 characters. You can choose the name on app creation in the dashboard or by running heroku apps:create APPNAME.

For example, if you create an app with the name example-app, you can access its info in the Heroku CLI with heroku apps:info --app example-app.

If you create an app without choosing a name, the platform generates one for you.

The Heroku platform also uses this app name as part of the app’s subdomain.

Subdomains

By default, apps are accessible at their Heroku domains, which have the format of APPNAME-IDENTIFIER.herokuapp.com or APPNAME-IDENTIFIER.DNS-ZONE.herokuapp.com. The subdomain is the APPNAME-IDENTIFIER part, your app name combined with a 12-character random identifier. For example, example-app-1234567890ab.

The exceptions to this format are if you configured Review Apps to use a predictable URL.

You can rename apps at any time, which results in a new subdomain. See Renaming Apps from the CLI for more info. Renaming an app destroys the old subdomain and creates a new one. The addition of the identifier helps to mitigate the reuse of subdomains.

For info on adding custom domains, including adding a custom domain with a subdomain, see Custom Domain Names For Apps.

While your app is available at your subdomain, we strongly recommend adding custom domains for production apps.

 

Heroku started appending identifiers to subdomains on June 14, 2023. Applications created before this date maintain the old subdomain scheme where the subdomain was the same as the app name. Renaming these apps results in subdomains using the current scheme of APPNAME-IDENTIFIER.herokuapp.com.

Subdomain Reuse Mitigation

A subdomain takeover occurs when an attacker gains control of a target domain. Typically, takeovers happen when an application is deprecated, but its old URL remains active and can still receive traffic from legacy users. An attacker can create an app at that URL and intercept the traffic and provide their own content. This takeover can lead to phishing attacks, cookie theft, and bypassing OAuth allowlisting. The addition of a random identifier helps to prevent subdomain names from being taken over after apps are deleted or renamed.

Configuring Review Apps to use a predictable URL can expose those apps for a possible subdomain takeover.

URLs

By default, apps are accessible at their Heroku domains:

  • Cedar-generation apps have the format of APPNAME-IDENTIFIER.herokuapp.com, where APPNAME-IDENTIFIER is the subdomain. For example, example-app-1234567890ab.herokuapp.com.
  • Fir-generation apps use sharded DNS zones, and have a domain format of APPNAME-IDENTIFIER.DNS-ZONE.herokuapp.com. For example,example-app-1234567890ab.redwood-oregon.herokuapp.com.

For info on adding custom domains, including adding a custom domain with a subdomain, see Custom Domain Names For Apps.

Keep reading

  • App Security

Feedback

Log in to submit feedback.

WebSocket Security Heroku SSL

Information & Support

  • Getting Started
  • Documentation
  • Changelog
  • Compliance Center
  • Training & Education
  • Blog
  • Support Channels
  • Status

Language Reference

  • Node.js
  • Ruby
  • Java
  • PHP
  • Python
  • Go
  • Scala
  • Clojure
  • .NET

Other Resources

  • Careers
  • Elements
  • Products
  • Pricing
  • RSS
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku Blog
    • Heroku News Blog
    • Heroku Engineering Blog
  • Twitter
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku
    • Heroku Status
  • Github
  • LinkedIn
  • © 2025 Salesforce, Inc. All rights reserved. Various trademarks held by their respective owners. Salesforce Tower, 415 Mission Street, 3rd Floor, San Francisco, CA 94105, United States
  • heroku.com
  • Legal
  • Terms of Service
  • Privacy Information
  • Responsible Disclosure
  • Trust
  • Contact
  • Cookie Preferences
  • Your Privacy Choices