DEV Community

Cover image for AWS Lambda Web Functions Run Your Express App As-Is. When I'd Move and When Not
Mango Developer
Mango Developer

Posted on Originally published at mangodeveloper.com

AWS Lambda Web Functions Run Your Express App As-Is. When I'd Move and When Not

For years the awkward truth about Lambda was that your web app had to be rewritten, or wrapped in an adapter, before it could run there. Anyone who has tried to run a normal Express app on Lambda knows the feeling: you've got a perfectly good server, and now you're translating HTTP requests into events and back again. AWS's new Lambda Web Functions are an attempt to make that whole step disappear.

The announcement came in AWS's weekly roundup dated October 19, and it's worth more attention than a roundup bullet. I'll go through what it does, what the billing change means in practice, and where I'd stay on containers.

What Web Functions are

According to the AWS News Blog, Lambda Web Functions is a new form factor that runs a standard HTTP web application on Lambda without rewriting it into an event handler. You take a server that listens on a port, built with Express, Hono, Fastify or Next.js, run aws lambda-web deploy, and get back a live HTTPS URL in under a minute. AWS says there are no adapters, no infrastructure to set up first and no framework lock-in.

That gives Lambda three form factors on the same Firecracker isolation, which AWS says compose inside one application:

Form factor Best for
Event Functions Async work, the model you already know
Web Functions The user-facing layer, plain HTTP servers
MicroVMs Stateful sandboxes running untrusted code

The two details that change the maths

Lots of products promise "just deploy your app". The two details that make this one more than repackaging, per AWS, are concurrency and billing.

First, each execution environment handles up to 128 concurrent requests. Classic Lambda maps one request to one environment. If a burst of traffic arrives, you get many environments, each cold-starting separately. With Web Functions, a burst shares warm environments instead. For a web server, which is built to handle many connections at once, this is the model it was designed for.

Second, billing meters the CPU time your code actually uses rather than wall-clock time. Think about what a typical request does: it waits on a database, waits on an API, waits on a model streaming tokens. In a wall-clock model, you pay for all that waiting. In a CPU-time model, you don't. AWS specifically points to server-side rendering, API backends, and inference endpoints that stream tokens as workloads where most of the elapsed time is spent waiting, and says that changes the arithmetic.

I'd treat that as a hypothesis to test, not a guarantee. AWS hasn't put prices in the roundup, so I can't tell you what your bill will look like. Run your own numbers with real traffic.

Deploy details worth knowing

A few specifics from the post:

  • Adding --regions to the same deploy command replicates your code and configures latency-based routing behind a single global URL.
  • You can split traffic across revisions by weight, which gives you a canary rollout without extra tooling.
  • It's available in five Regions, running Node.js 24 on Arm64, with VPC connectivity.
  • Amazon CloudFront can now use a Web Function endpoint as an origin with origin access control.

The AWS Compute Blog has a longer walkthrough. I haven't deployed anything with it yet, so I'm relying on AWS's description, and you should read that walkthrough before moving production traffic.

When I'd move to it

My rough guide, labelled as my opinion:

  • You have a mostly stateless Express, Hono or Fastify API. The pitch is exactly your use case, and the migration cost looks like a deploy command rather than a rewrite.
  • Your traffic is spiky. Scale-to-zero plus shared warm environments is the sweet spot, and a container service with a minimum task count wastes money overnight.
  • You're streaming tokens from a model. Long wait times and little CPU are what CPU-time billing rewards.
  • You want multi-region without running multi-region infrastructure. The --regions flag is attractive if it works as described.

When I wouldn't

  • You need a runtime other than Node.js 24. The post only mentions Node.js 24 on Arm64, so check support for anything else before planning.
  • You're outside the five Regions. AWS didn't list them in the roundup, so look at the Compute Blog.
  • Your app holds state in memory between requests. Shared environments help throughput, but you still shouldn't rely on in-process state in a serverless model.
  • You already run steady, high traffic on containers with predictable costs. The savings story is strongest for idle-heavy, bursty workloads.

The rest of the week's AWS news

A few other items from the same roundup that caught my attention:

Amazon S3 is now available on the Vercel Marketplace and in v0 by Vercel, so you can provision general purpose buckets, S3 Tables and S3 Vectors from the Vercel dashboard. The detail I like is authentication: a short-lived OIDC token is exchanged at runtime with AWS Security Token Service for credentials scoped to that resource, so no static keys are stored anywhere.

Amazon EC2 T8i instances reached the São Paulo Region. AWS says T8i delivers up to 30 percent better price performance than T3, with up to 70 percent higher compute performance and 2.4 times the Amazon EBS bandwidth, keeps the same CPU credit system, and t8i.micro and t8i.small are available under the Free Tier.

Reflection Beam, an open-weight agentic coding model with 501 billion total and 23 billion active parameters under Apache 2.0, is now deployable from SageMaker JumpStart. The AWS Lambda Durable Execution SDK for Go is generally available, letting you write multi-step workflows that checkpoint progress and pause for up to a year. And Amazon CloudWatch added log routing and chained log parsers.

The counterweight: trust in depth

AWS's roundup frames the week as making it easier to put things into production and says it matters more that you can say what those things are allowed to do. The second headline is an article called "Trust in Depth: giving agents more autonomy without losing control."

The argument, as the roundup summarizes it, is that putting a person in the loop for every agent action works at small scale and then quietly stops working, because people asked to check everything stop catching what matters. The alternative is four questions answered at four moments: scope, know, bound and observe. The key idea is that an agent's limits belong outside its own reasoning, in Amazon Bedrock AgentCore policies enforced at the gateway, because an agent can't turn off a control it doesn't run.

That applies to Web Functions too. The faster you can ship a URL, the more important it is to know what that URL can reach. Before you deploy, decide what IAM permissions the function gets, and keep them narrow.

What I'd do this week

  1. Pick one low-risk service, like an internal API or a webhook receiver, and deploy it as a Web Function.
  2. Compare real CPU-time billing against your current container cost for a week.
  3. Test a canary split with weighted revisions before trusting it with anything important.
  4. Review the IAM role attached to the function.

Should you care?

If you've avoided Lambda because of adapter friction, yes. If you're happy on containers, there's no urgency, but this removes one of the best arguments against serverless web apps.

Frequently Asked Questions

What are AWS Lambda Web Functions?

A new Lambda form factor that runs a standard HTTP web application, such as Express, Hono, Fastify or Next.js, without rewriting it into an event handler.

How is it billed?

AWS says billing meters the CPU time your code actually uses rather than wall-clock time. The roundup doesn't list prices.

Where is it available?

Five Regions, running Node.js 24 on Arm64 with VPC connectivity. Check the AWS Compute Blog for the Region list.

Does it work with CloudFront?

Yes. Amazon CloudFront can now use a Web Function endpoint as an origin with origin access control.


Originally published on Mango Developer.

Top comments (1)

Collapse
 
userxnom profile image
Abdullah Naseer •

The 128-concurrent-requests detail is the one that changes the maths for me — classic Lambda's one-request-per-environment model is exactly what made small APIs feel wasteful, and CPU-time billing finally rewards the idle-waiting shape of a token-streaming endpoint. The honest caveat you flagged matters too: no prices in the roundup yet, so that week-long cost comparison against containers is the real test before moving anything that matters. Which low-risk service are you going to try first — the webhook receiver or an internal API?