Heroku vs Railway
A comparison of Heroku and Railway built from values read directly from each provider's own documentation, with the source recorded against every figure.
The short answer
- Pick Heroku if
- Teams that want to deploy by pushing to Git and let the platform handle the runtime, with Postgres, a scheduler and Docker deploys available on the same platform.
- Pick Railway if
- Teams that want a plan fee which doubles as usage credit, and deploy services straight from a Dockerfile without managing servers. The $5 Hobby fee comes back as $5 of resource usage.
10 sourced criteria separate them:
- Entry paid plan
- Heroku: $5 per month (Eco dynos plan, 1000 dyno hours shared across the account)
- Railway: $5 / month (Hobby)
- Pricing model
- Heroku: Usage-based on wall-clock time, prorated to the second
- Railway: Plan fee that includes an equivalent usage credit
- When you exceed a cap
- Heroku: Service sleeps: on the Eco plan ($5/month for a 1000 dyno-hour pool, the cheapest paid tier) exhausting the pool forces every Eco dyno on the account to sleep for the rest of the month, and extra hours cannot be bought
- Railway: Billed automatically: on the Hobby plan ($5/month, includes $5 of resource usage) usage above the included amount is charged as a delta on top of the subscription — no throttling or suspension is documented
- Sites or apps included
- Heroku: 100 apps per account, platform-wide on all plans (Heroku Team 100, Enterprise Team 200)
- Railway: 50 projects and 50 services on the Hobby plan ($5/month); 3 members per project (Pro: 100 projects, 100 services)
- Max request duration
- Heroku: 30 seconds (initial window for the web process to return response data)
- Railway: 15 minutes while data keeps transferring; closed after 5 minutes with no data transferred. Websocket connections are exempt and can stay open indefinitely.
- Streaming response limit
- Heroku: Platform-wide (router): 30 seconds to send the first byte, then a rolling 55-second idle window — if no data is sent for 55 seconds the connection is terminated
- Railway: Platform-wide: a stream that keeps transferring data may run up to 15 minutes; a connection with no data transferred is closed after 5 minutes. Idle HTTP/1.1 connections are closed after 60 seconds between requests. WebSocket connections are exempt.
- Managed connection pooling
- Heroku: Limited
- Railway: Supported
- Persistent storage
- Heroku: Not supported
- Railway: Supported
- Managed databases
- Heroku: Supported
- Railway: Limited
- Regions
- Heroku: Common Runtime: us (United States), eu (Europe). Private Spaces: Dublin, Frankfurt, London, Montreal, Mumbai, Oregon, Singapore, Sydney, Tokyo, Virginia
- Railway: 4 regions: California, Virginia, Amsterdam, Singapore
At a glance.
| Criterion | Heroku | Railway |
|---|---|---|
| Pricing | ||
| Entry paid plan | $5 per month (Eco dynos plan, 1000 dyno hours shared across the account) | $5 / month (Hobby) |
| Pricing model | Usage-based on wall-clock time, prorated to the second | Plan fee that includes an equivalent usage credit |
| When you exceed a cap | Service sleeps: on the Eco plan ($5/month for a 1000 dyno-hour pool, the cheapest paid tier) exhausting the pool forces every Eco dyno on the account to sleep for the rest of the month, and extra hours cannot be bought | Billed automatically: on the Hobby plan ($5/month, includes $5 of resource usage) usage above the included amount is charged as a delta on top of the subscription — no throttling or suspension is documented |
| Limits | ||
| Sites or apps included | 100 apps per account, platform-wide on all plans (Heroku Team 100, Enterprise Team 200) | 50 projects and 50 services on the Hobby plan ($5/month); 3 members per project (Pro: 100 projects, 100 services) |
| Max request duration | 30 seconds (initial window for the web process to return response data) | 15 minutes while data keeps transferring; closed after 5 minutes with no data transferred. Websocket connections are exempt and can stay open indefinitely. |
| Execution | ||
| Streaming response limit | Platform-wide (router): 30 seconds to send the first byte, then a rolling 55-second idle window — if no data is sent for 55 seconds the connection is terminated | Platform-wide: a stream that keeps transferring data may run up to 15 minutes; a connection with no data transferred is closed after 5 minutes. Idle HTTP/1.1 connections are closed after 60 seconds between requests. WebSocket connections are exempt. |
| Managed connection pooling | Limited | Supported |
| Deployment | ||
| Git deployment | Supported | Supported |
| Docker deployment | Supported | Supported |
| Scheduled jobs | Supported | Supported |
| Infrastructure | ||
| Persistent processes | Supported | Supported |
| Persistent storage | Not supported | Supported |
| Managed databases | Supported | Limited |
| Scales to zero | Limited | Limited |
| Autoscaling | Limited | Limited |
| Regions | Common Runtime: us (United States), eu (Europe). Private Spaces: Dublin, Frankfurt, London, Montreal, Mumbai, Oregon, Singapore, Sydney, Tokyo, Virginia | 4 regions: California, Virginia, Amsterdam, Singapore |
Where they differ.
Entry paid plan
- Heroku
- $5 per month (Eco dynos plan, 1000 dyno hours shared across the account)
- Railway
- $5 / month (Hobby)
Sources (2) →Sources ↓
- Eco Dyno Hours | Heroku Dev Center ↗
“The Eco dynos plan provides 1000 dyno hours for $5 per month. This dyno hours pool is shared by all Eco dynos in your account.”
Read 2026-09-05 · official docs
- Railway plans ↗
“Hobby Plan: For indie hackers and developers to build and deploy personal projects — $5/month”
Read 2026-09-05 · official docs
Pricing model
- Heroku
- Usage-based on wall-clock time, prorated to the second
- Railway
- Plan fee that includes an equivalent usage credit
Sources (2) →Sources ↓
- Usage & Billing | Heroku Dev Center ↗
“Heroku computes usage from wall-clock time, not CPU time. Any dynos scaled above 0 accrue usage, regardless of traffic or activity. Heroku prorates all costs to the second.”
Read 2026-09-05 · official docs
- Railway plans ↗
“The Hobby plan includes $5 of resource usage per month. The Pro plan includes $20 of resource usage per month.”
Read 2026-09-05 · official docs
When you exceed a cap
- Heroku
- Service sleeps: on the Eco plan ($5/month for a 1000 dyno-hour pool, the cheapest paid tier) exhausting the pool forces every Eco dyno on the account to sleep for the rest of the month, and extra hours cannot be bought
- Railway
- Billed automatically: on the Hobby plan ($5/month, includes $5 of resource usage) usage above the included amount is charged as a delta on top of the subscription — no throttling or suspension is documented
Sources (2) →Sources ↓
- Eco Dyno Hours | Heroku Dev Center ↗
“When you use all your Eco dyno hours for a given month, all Eco dynos on your account are forced to sleep for the rest of the month. You can't purchase additional dyno hours.”
Read 2026-09-05 · official docs
- Pricing Plans | Railway Docs ↗
“If your total resource usage exceeds $5 in any given billing period, you will be charged the delta”
Read 2026-09-05 · official docs
Sites or apps included
100 apps per account, platform-wide on all plans (Heroku Team 100, Enterprise Team 200)
50 projects and 50 services on the Hobby plan ($5/month); 3 members per project (Pro: 100 projects, 100 services)
Sources (2) →Sources ↓
- Limits | Heroku Dev Center ↗
“An account can have up to 100 apps.”
Read 2026-09-05 · official docs
- Pricing | Railway ↗
“Projects | 50 | 100”
Read 2026-09-05 · official pricing
Max request duration
- Heroku
- 30 seconds (initial window for the web process to return response data)
- Railway
- 15 minutes while data keeps transferring; closed after 5 minutes with no data transferred. Websocket connections are exempt and can stay open indefinitely.
Sources (2) →Sources ↓
- Limits | Heroku Dev Center ↗
“HTTP requests have an initial 30 second window for the web process to return response data. It can be either the completed response or some amount of response data to indicate that the process is active. Processes that fail to send response data within the initial 30-second window see an H12 error in their logs.”
Read 2026-09-05 · official docs
- Specs & Limits — Railway Docs ↗
“HTTP requests can run for up to 15 minutes if data keeps transferring (for example, keep-alive heartbeats), and are otherwise closed after 5 minutes with no data transferred. [...] Websocket connections are exempt from these duration and inactivity limits, and can stay open indefinitely, even while idle.”
Read 2026-09-05 · official docs
Streaming response limit
- Heroku
- Platform-wide (router): 30 seconds to send the first byte, then a rolling 55-second idle window — if no data is sent for 55 seconds the connection is terminated
- Railway
- Platform-wide: a stream that keeps transferring data may run up to 15 minutes; a connection with no data transferred is closed after 5 minutes. Idle HTTP/1.1 connections are closed after 60 seconds between requests. WebSocket connections are exempt.
Sources (2) →Sources ↓
- Request Timeout | Heroku Dev Center ↗
“Heroku supports HTTP features such as long-polling and streaming responses. An application has an initial 30 second window to respond with a single byte back to the client. However, each byte transmitted thereafter (either received from the client or sent by your application) resets a rolling 55 second window. If no data is sent during the 55 second window, the connection will be terminated.”
Read 2026-09-05 · official docs
- Specs & Limits ↗
“HTTP requests can run for up to 15 minutes if data keeps transferring (for example, keep-alive heartbeats), and are otherwise closed after 5 minutes with no data transferred. [...] Websocket connections are exempt from these duration and inactivity limits, and can stay open indefinitely, even while idle.”
Read 2026-09-05 · official docs
Managed connection pooling
- Heroku
- Limited
- Railway
- Supported
Sources (2) →Sources ↓
- Server-Side Connection Pooling for Heroku Postgres | Heroku Dev Center ↗
“Server-side connection pooling is available for Standard, Premium, Private, and Shield-tier databases. [...] Server-side connection pooling isn't available for Essential-tier databases.”
Read 2026-09-05 · official docs
- PostgreSQL Connection Pooling — Railway Docs ↗
“Railway can add PgBouncer as a connection pooler in front of your PostgreSQL service. PgBouncer multiplexes many application connections into a smaller pool of server connections, reducing overhead and allowing your database to serve far more concurrent clients than max_connections alone would permit.”
Read 2026-09-05 · official docs
Persistent storage
- Heroku
- Not supported
- Railway
- Supported
Sources (2) →Sources ↓
- Dynos (App Containers) | Heroku Dev Center ↗
“Each dyno gets its own ephemeral filesystem, with a fresh copy of the most recently deployed code. During the dyno's lifetime, its running processes can use the filesystem as a temporary scratchpad, but no files that are written are visible to processes in any other dyno.”
Read 2026-09-05 · official docs
- Volumes | Railway Docs ↗
“Volumes are a feature that enables persistent data for services on Railway. [...] When mounting a volume to a service, a volume is made available to the service on the specified mount path.”
Read 2026-09-05 · official docs
Managed databases
- Heroku
- Supported
- Railway
- Limited
Sources (2) →Sources ↓
- Heroku Postgres | Heroku Dev Center ↗
“Heroku Postgres is a managed SQL database service provided directly by Heroku. You can access a Heroku Postgres database from any language with a PostgreSQL driver, including all languages Heroku officially supports.”
Read 2026-09-05 · official docs
- Databases — Railway Docs ↗
“Railway enables you to deploy and manage databases alongside your applications. [...] The fastest way to deploy a database is through Railway's database templates [...] These templates are maintained by Railway and come pre-configured with sensible defaults.”
Read 2026-09-05 · official docs
Regions
- Heroku
- Common Runtime: us (United States), eu (Europe). Private Spaces: Dublin, Frankfurt, London, Montreal, Mumbai, Oregon, Singapore, Sydney, Tokyo, Virginia
- Railway
- 4 regions: California, Virginia, Amsterdam, Singapore
Sources (2) →Sources ↓
- Regions | Heroku Dev Center ↗
“eu Europe Common Runtime us United States Common Runtime dublin Dublin, Ireland Private Spaces frankfurt Frankfurt, Germany Private Spaces london London, United Kingdom Private Spaces montreal Montreal, Canada Private Spaces mumbai Mumbai, India Private Spaces oregon Oregon, United States Private Spaces singapore Singapore Private Spaces sydney Sydney, Australia Private Spaces tokyo Tokyo, Japan Private Spaces virginia Virginia, United States Private Spaces”
Read 2026-09-05 · official docs
- Railway regions ↗
“US West Metal — California, USA; US East Metal — Virginia, USA; EU West Metal — Amsterdam, Netherlands; Southeast Asia Metal — Singapore”
Read 2026-09-05 · official docs
Which should you choose?
Choose Heroku if…
Teams that want to deploy by pushing to Git and let the platform handle the runtime, with Postgres, a scheduler and Docker deploys available on the same platform.
Editorial · Palash Bagchi · approved
Choose Railway if…
Teams that want a plan fee which doubles as usage credit, and deploy services straight from a Dockerfile without managing servers. The $5 Hobby fee comes back as $5 of resource usage.
Editorial · Palash Bagchi · approved
Consider something else if…
- Heroku: The dyno filesystem is ephemeral, and a web process must respond within 30 seconds of receiving a request.
- Railway: You need to run in a region outside California, Virginia, Amsterdam or Singapore.
Documented by only one.
These criteria are published by one provider and not the other. An absence here means we have not found a source, not that the feature is missing.
