# Where to host a gRPC API in 2026, and which hosts scale it to zero

Gregale · Updated 2026-12-05

Which hosts pass gRPC through to your server, from Cloud Run and Fly.io to Render, Railway, Heroku and Koyeb, and which wake on a gRPC call. Tested on Gregale.

**Google Cloud Run, Fly.io and Gregale serve gRPC on an app's public URL;
Fly.io and Gregale need a setting that says the app speaks HTTP/2, and
Cloud Run needs one for streaming calls. Render says it doesn't yet support
gRPC over external connections, and Heroku ends HTTP/2 at its router.** Scaling to zero is where they differ most: Koyeb says an HTTP/2
request can't wake a sleeping service, while on Gregale the first gRPC call
wakes a parked server. In the production run below, a Python gRPC server
answered that call in about a second.

**[Follow the run](#verified-on-gregale-december-5-2026)**, or jump to
[the deploy steps](#deploy-a-grpc-server-on-gregale).

## Which platforms serve gRPC

Checked on each vendor's own pages on December 5, 2026:

| Platform         | gRPC on the public URL                                                          | Between services                                 | Scale to zero                                                                  | Longest call                                                    |
| ---------------- | ------------------------------------------------------------------------------- | ------------------------------------------------ | ------------------------------------------------------------------------------ | --------------------------------------------------------------- |
| Google Cloud Run | Yes; streaming RPCs need "Use HTTP/2 end-to-end" and an h2c server              | Through the service URL                          | Yes, by default                                                                | Request timeout: 5 minutes by default, up to 60                 |
| Fly.io           | Yes, with `h2_backend = true` and an h2c server                                 | Private network, not through the proxy           | Yes, auto-stop; a cold start "takes about 2 seconds or more"                   | Not stated                                                      |
| Render           | "Doesn't yet have native support" over external connections                     | Private services take any protocol               | Free web services spin down after 15 idle minutes; waking takes about a minute | Not stated                                                      |
| Railway          | HTTP/1.1 and HTTP/2 from the internet; gRPC not named                           | Private network carries any TCP                  | Serverless sleeps 5 to 10 minutes after the last outbound traffic              | 15 minutes while data flows, 5 minutes with none                |
| Heroku           | No: HTTP/2 ends at the router, which sends HTTP/1.1 to the app (Common Runtime) | Not stated                                       | Eco dynos sleep after 30 idle minutes                                          | 30 seconds to the first byte, then a rolling 55-second window   |
| Koyeb            | HTTP/2 can be chosen per port; gRPC not named                                   | Service mesh for ports that are not public       | Yes, in public preview, but HTTP/2 requests can't wake a service               | Not stated                                                      |
| Gregale          | Yes, with `--app-protocol grpc` and an h2c server                               | `http://APP.svc.gregale:10081`, plaintext HTTP/2 | Yes; a gRPC call wakes a parked app                                            | Streams about 15 minutes; a unary call by plan, 1 to 15 minutes |

"h2c" is HTTP/2 without TLS. Each of these platforms ends TLS at its edge,
so the server listens in plaintext and clients connect with TLS on port 443,
the way they would to any other gRPC endpoint.

## Verified on Gregale, December 5, 2026

The test app, `grpc-greeter`, is a Python server built with `grpcio` from
this proto:

```proto
service Greeter {
  rpc SayHello (google.protobuf.StringValue) returns (google.protobuf.StringValue);
  rpc Count (google.protobuf.Int32Value) returns (stream google.protobuf.Int32Value);
}
```

It also serves the standard `grpc.health.v1.Health` service and server
reflection, and listens on `$PORT` without TLS. The deploy built the image
and took the snapshot in 62 seconds. The client was a Go program on a
laptop in Turkey, calling `grpc-greeter.gregale.app:443` over TLS:

| Call                                  | Result                                 | Time     |
| ------------------------------------- | -------------------------------------- | -------- |
| `SayHello("Gregale")`, new connection | `OK`, `Hello, Gregale`                 | 941 ms   |
| `Health/Check`, same connection       | `OK`, `SERVING`                        | 166 ms   |
| `SayHello("")`                        | `INVALID_ARGUMENT`, `name is required` | 175 ms   |
| A method the server lacks             | `UNIMPLEMENTED`, `Method not found!`   | 165 ms   |
| `Count(5)`, server stream             | `OK`, 5 messages, one a second         | 5,170 ms |

The app's own status codes and messages reached the client unchanged, so
the `grpc-status` trailer made it through. The stream's messages arrived at
162, 1,162, 2,163, 3,163 and 4,164 ms, as the server sent them, not in one
batch at the end. Twenty more calls, each on a new connection, all
returned `OK`. A call on a new connection took 0.7 to 1.2 seconds, with
the laptop in Turkey and the app's server in North America.

**Waking from parked.** The idle timeout was set to 60 seconds. On this
app's node an idle instance is first frozen in memory, and it parks to its
snapshot 10 minutes later. Thirteen minutes after the last call, a `SayHello` on a new
connection restored the app from its snapshot (`x-faas-wake: restored`,
with a new wake ID) and returned `OK` in 1,063 ms; the next call on a new
connection took 720 ms. A call under 4 minutes after the one before resumed
the frozen instance instead and took 908 ms.

**Between services.** From `gregale app exec`, which runs a command in a
fresh VM of the app, a plaintext `grpcio` channel to
`grpc-greeter.svc.gregale:10081` got `SERVING` from the health check in
39 ms and the `SayHello` reply in 8 ms; the empty name came back as
`INVALID_ARGUMENT` there too.

## Deploy a gRPC server on Gregale

Have the server listen on `$PORT` without TLS, and serve
`grpc.health.v1.Health` so Gregale can tell when it's ready:

```python
server = grpc.server(futures.ThreadPoolExecutor(max_workers=16))
greeter_pb2_grpc.add_GreeterServicer_to_server(Greeter(), server)
health_servicer = health.HealthServicer()
health_pb2_grpc.add_HealthServicer_to_server(health_servicer, server)
health_servicer.set("", health_pb2.HealthCheckResponse.SERVING)
server.add_insecure_port(f"[::]:{os.environ.get('PORT', '8080')}")
server.start()
server.wait_for_termination()
```

Then deploy it with the gRPC protocol and the gRPC health check:

```bash
gregale deploy --name my-grpc-api --app-protocol grpc --healthcheck-grpc
```

A new app on Hobby and above takes calls only with a Gregale API key. For a
public API, add `access: public` to `gregale.yaml`, or keep the key and send
it as a bearer token in the call's metadata. Clients connect to
`my-grpc-api.gregale.app:443` with TLS. An existing app switches with
`gregale app update my-grpc-api --app-protocol grpc`, and a service in a
Compose project declares `x-gregale-app-protocol: grpc` (see
[multi-service apps](https://gregale.dev/docs/multi-service.md)).

Other services in the same account call it at
`my-grpc-api.svc.gregale:10081` with a plaintext channel; see
[internal services](https://gregale.dev/docs/internal-services.md).

## Limits

- gRPC needs a paid plan; the Free plan refuses it
  (`plan_app_protocol_grpc_not_allowed`). Hobby costs $10 a month.
- A streaming RPC lasts at most about 15 minutes, on every plan. Write
  clients to open a new stream and resume from the last message they
  processed; see [long-lived streams](https://gregale.dev/docs/networking.md#long-lived-streams).
- A unary call ends at the plan's request timeout: 1 minute on Hobby,
  5 on Pro and 15 on Scale.
- gRPC-Web is not translated. A browser client needs a proxy such as Envoy
  in front, or a server that speaks gRPC-Web itself.
- When Gregale refuses a call before it reaches your app, for example for a
  missing API key or a rate limit, the client gets a gRPC status such as
  `UNAUTHENTICATED` with the reason in `grpc-message`, not an HTML error
  page.

**Choose something else when:**

- **You need streams longer than 15 minutes.** Cloud Run's request timeout
  goes up to 60 minutes.
- **Your clients are browsers.** gRPC-Web or Connect needs a translating
  proxy on any of these platforms; a JSON API may be simpler.

## Sources

Gregale facts come from the production run above, the
[networking docs](https://gregale.dev/docs/networking.md), the
[container compatibility docs](https://gregale.dev/docs/container-compatibility.md), the
[multi-service docs](https://gregale.dev/docs/multi-service.md), the [plans](https://gregale.dev/docs/plans.md) and the
[error codes](https://gregale.dev/docs/error-codes.md). Other platforms, checked December 5, 2026:
[Cloud Run gRPC](https://docs.cloud.google.com/run/docs/triggering/grpc),
[Cloud Run HTTP/2](https://docs.cloud.google.com/run/docs/configuring/http2),
[Cloud Run request timeout](https://docs.cloud.google.com/run/docs/configuring/request-timeout),
[Cloud Run minimum instances](https://docs.cloud.google.com/run/docs/configuring/min-instances),
[Fly.io services](https://docs.fly.io/networking/services),
[Fly.io autostop](https://docs.fly.io/launch/autostop-autostart),
[Fly.io private networking](https://docs.fly.io/networking/private-networking),
[Render Temporal guide](https://render.com/docs/deploy-temporal),
[Render private network](https://render.com/docs/private-network),
[Render free instances](https://render.com/docs/free),
[Railway public networking limits](https://docs.railway.com/networking/public-networking/specs-and-limits),
[Railway private networking](https://docs.railway.com/networking/private-networking/how-it-works),
[Railway Serverless](https://docs.railway.com/reference/app-sleeping),
[Heroku HTTP routing](https://devcenter.heroku.com/articles/http-routing),
[Heroku Eco dynos](https://devcenter.heroku.com/articles/eco-dyno-hours),
[Koyeb exposing a service](https://www.koyeb.com/docs/build-and-deploy/exposing-your-service),
[Koyeb scale to zero](https://www.koyeb.com/docs/run-and-scale/scale-to-zero).

## Questions

### Which hosting platforms support gRPC?

Google Cloud Run, Fly.io and Gregale serve gRPC on an app's public URL. Fly.io needs h2_backend = true and Gregale needs --app-protocol grpc; Cloud Run needs its HTTP/2 end-to-end setting for streaming calls. Render's docs say it doesn't yet support gRPC over external connections, and Heroku ends HTTP/2 at its router and sends HTTP/1.1 to the app.

### Can a gRPC server scale to zero?

On Cloud Run, Fly.io and Gregale, yes. Koyeb can scale a service to zero, but its docs say an HTTP/2 request cannot wake a sleeping service. On Gregale the first gRPC call wakes a parked app: in a production run on December 5, 2026, it returned OK in about a second.

### Does my gRPC server need TLS?

No. Cloud Run, Fly.io and Gregale end TLS at their edge and talk to your server over HTTP/2 without TLS (h2c), so the server listens in plaintext on its port and clients connect with TLS on port 443.

### How long can a gRPC stream stay open?

On Gregale, about 15 minutes on every plan; clients should open a new stream and resume where they left off. Cloud Run ends a call at its request timeout, 5 minutes by default and up to 60. Railway keeps a request for up to 15 minutes while data flows.

### Can I call a gRPC service from another service on Gregale?

Yes. Other apps in the account reach it at APP.svc.gregale:10081 with a plaintext channel. In the production run, a health check over that address took 39 ms and a unary call 8 ms.

Canonical URL: https://gregale.dev/articles/where-to-host-grpc-api

