Azure Functions

Azure Functions vs Cloud Run: which is better for containerized services?

Answer:

Cloud Run is the better default for containerized services: it runs any OCI container image built on the Knative Serving API and scales to zero automatically, while Azure Functions only supports custom containers on Premium or Dedicated (App Service) plans, not the default Consumption plan. Pick between them based on how the workload is triggered and how the team already builds.

When is Azure Functions the right call?

Azure Functions fits when the workload is genuinely event-driven and you want to lean on its triggers-and-bindings model, for example reacting to Blob Storage uploads, Service Bus messages, or Cosmos DB changes without writing glue code. If a container is still required, it has to run on an Elastic Premium (EP1 and similar SKUs) or Dedicated App Service plan, since those are the tiers Microsoft documents as supporting custom Linux container images. Teams already standardized on Azure infrastructure, Entra ID, and Azure DevOps pipelines also gain from staying in one ecosystem rather than adding a second cloud provider for one service.

What if you don't need a custom container at all?

If the function is simple, short-lived code without unusual dependencies, the Consumption plan is cheaper and simpler than either containerized option, so this comparison only matters once packaging requirements push you toward containers in the first place.

When is Cloud Run the right call?

Cloud Run is the better fit when the team already has a Dockerfile or existing container image and wants to deploy it with minimal rework. Because it implements the Knative Serving API, any standard container runs the same way whether it targets Cloud Run, GKE, or another Knative-compatible platform, which reduces lock-in. It also scales to zero on its own and bills for actual CPU and request usage, so intermittent HTTP services and APIs with unpredictable traffic don't pay for idle compute. This makes it a natural choice for services written in languages or frameworks Azure Functions doesn't support well out of the box, or for teams that want one deployment model across many services.

Does the trigger model matter for the decision?

Yes. Cloud Run services are primarily invoked over HTTP or through Pub/Sub push subscriptions, so workloads that need native bindings to a wide variety of event sources still lean toward Azure Functions or another trigger-rich FaaS platform, even when running in a container.

Implementation note

Before committing, confirm which Azure Functions plan the workload actually needs. Choosing Consumption by default and then discovering custom containers aren't supported there is a common source of rework, so check the container requirement against the plan tier at the start of the design, not after deployment.

Curved left line
We're Here to Help

Thinking about how to expand a tech team flexibly to adapt to different working paces?

Accelerate development, meet launch deadlines with flexible, much-needed capacity. Add new skills your team currently lacks.

Curved right line