Table of Contents
This article describes a beta feature. Functionality may change prior to general availability.
Heroku is available in two geographic regions: the US and EU. The EU region is beta.
You can choose your app’s region to minimize latency for your end users. I.e. if your users are primarily in Europe your app will be faster for them if it’s running in Europe.
Select a region
Unless specified, all apps will be created in the
us region. To specify a different region, use the
--region flag when creating the app:
$ heroku create --region eu Creating calm-ocean-1234... done, region is eu http://calm-ocean-1234.herokuapp.com/ | email@example.com:calm-ocean-1234.git Git remote heroku added
Existing applications can be migrated to a new region.
To verify the app’s region, check the
Region attribute of the
heroku info command:
$ heroku info === calm-ocean-1234 Git URL: firstname.lastname@example.org:calm-ocean-1234.git Owner Email: email@example.com Region: eu Repo Size: 164M ...
List all available regions with:
$ heroku regions === regions eu Europe us United States
Add-ons with region support will be provisioned in the same region as the app. Provision them as you normally would:
$ heroku addons:add heroku-postgresql
Add-ons that don’t require a low-latency connection to your app will be provisioned in the default region if unavailable in your app’s region. If an add-on is latency sensitive and is not available in the same region as your app, provisioning will fail:
$ heroku addons:add cloudcounter Adding cloudcounter on calm-ocean-1234... failed ! This app is in region eu, cloudcounter:basic is only available in region us.
You can find add-ons supporting your app’s region using both the CLI and the web interface. To find add-ons supported in the
eu region using the CLI, run this command:
$ heroku addons:list --region=eu
On addons.heroku.com you can use the search box to find add-ons that support the
eu region by searching for “europe”. You can narrow your search further, for example to Redis add-ons that support the
eu region by searching for “Redis europe”.
Deployment & dynos
Apps are deployed to the region specified on creation. Deploy your app with git, as usual:
$ git push heroku master
Adding custom domains to apps running outside the
us region is the same as addin domains to apps in the
us region. Add the following CNAME record in your DNS provider’s control panel (substituting
example with the name of your Heroku app).
This will route all traffic addressed to
A-records are not supported on Heroku. If you wish to host an apex domain like “example.com” on Heroku you must do so using an ALIAS or similar record from your DNS provider that allows for an apex domain to CNAME mapping.
To utilize SSL, provision an SSL Endpoint for your application and upload your SSL certs.
$ heroku addons:add ssl Adding ssl on example... done, v1 ($20/mo) Next add your certificate with `heroku certs:add PEM KEY`. Use `heroku addons:docs ssl` to view documentation. $ heroku certs:add server.crt server.key Resolving trust chain... done Adding SSL Endpoint to example... done example now served by example.herokuapp.com
If your custom domain is properly configured, no additional DNS configuration is required (this differs from the
us region behavior, which requires using a domain like
tokyo-123.herokussl.com). All traffic to
www.example.com can now be served over SSL.
Data center locations
|Region Name||Data Center Location|
Safe Harbor & data residency
Although each supported region represents a geographically isolated platform runtime, no assumptions should be made about the physical residency of your application data.
Consider the following cases where data is stored in a different location than your app:
- Some non-latency sensitive add-ons can be provisioned in a different region as your app.
- Application logs are routed to Logplex, currently hosted in the US.
- PG Backup snapshots are stored in the US, and WAL files continuously sent to the US.
- No guarantees are made about the physical location of Heroku’s control surface APIs through which all CLI commands and the management of your applications occur.
The public beta of Regions is not designed to address data protection issues and, for this reason, is not Safe Harbor certified. Please choose a region based on the location of your users, not the laws that govern your data.
Migrating existing apps
Existing applications can migrate to a new region.