Articles

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

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.

Updated

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, or jump to the deploy steps.

Which platforms serve gRPC

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

PlatformgRPC on the public URLBetween servicesScale to zeroLongest call
Google Cloud RunYes; streaming RPCs need "Use HTTP/2 end-to-end" and an h2c serverThrough the service URLYes, by defaultRequest timeout: 5 minutes by default, up to 60
Fly.ioYes, with h2_backend = true and an h2c serverPrivate network, not through the proxyYes, auto-stop; a cold start "takes about 2 seconds or more"Not stated
Render"Doesn't yet have native support" over external connectionsPrivate services take any protocolFree web services spin down after 15 idle minutes; waking takes about a minuteNot stated
RailwayHTTP/1.1 and HTTP/2 from the internet; gRPC not namedPrivate network carries any TCPServerless sleeps 5 to 10 minutes after the last outbound traffic15 minutes while data flows, 5 minutes with none
HerokuNo: HTTP/2 ends at the router, which sends HTTP/1.1 to the app (Common Runtime)Not statedEco dynos sleep after 30 idle minutes30 seconds to the first byte, then a rolling 55-second window
KoyebHTTP/2 can be chosen per port; gRPC not namedService mesh for ports that are not publicYes, in public preview, but HTTP/2 requests can't wake a serviceNot stated
GregaleYes, with --app-protocol grpc and an h2c serverhttp://APP.svc.gregale:10081, plaintext HTTP/2Yes; a gRPC call wakes a parked appStreams 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:

CallResultTime
SayHello("Gregale"), new connectionOK, Hello, Gregale941 ms
Health/Check, same connectionOK, SERVING166 ms
SayHello("")INVALID_ARGUMENT, name is required175 ms
A method the server lacksUNIMPLEMENTED, Method not found!165 ms
Count(5), server streamOK, 5 messages, one a second5,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).

Other services in the same account call it at my-grpc-api.svc.gregale:10081 with a plaintext channel; see internal services.

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.
  • 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, the container compatibility docs, the multi-service docs, the plans and the error codes. Other platforms, checked December 5, 2026: Cloud Run gRPC, Cloud Run HTTP/2, Cloud Run request timeout, Cloud Run minimum instances, Fly.io services, Fly.io autostop, Fly.io private networking, Render Temporal guide, Render private network, Render free instances, Railway public networking limits, Railway private networking, Railway Serverless, Heroku HTTP routing, Heroku Eco dynos, Koyeb exposing a service, Koyeb 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.