Skip to main content

AWS Lambda Web Functions

Serverless compute for HTTP workloads

What is AWS Lambda Web Functions?

Bring the web framework you already use, like Express or Hono, and run it on Lambda with no code changes. Your code listens on a port and handles requests as it would on any HTTP server. Deploy once and replicate your code across the Regions you choose, with latency-based routing that sends each request to the Region closest to your users. A single warm environment serves many concurrent requests, so responses stay fast and consistent. You pay for active CPU time and the memory your environment consumes, not for CPU time your code spends waiting on databases or downstream services.

Benefits of AWS Lambda Web Functions

    Web Programming Model. Express, Hono, Fastify run without code changes. No handler adapters or proprietary APIs required.

    512 MB deployment packages. Full runtimes with large development packages.

    Native AWS service access. Connect to AWS services like DynamoDB, S3, Bedrock, and Aurora DSQL using the standard AWS SDK. Same IAM, same patterns you use today.
     

    Multi-concurrency. Each execution environment handles multiple requests simultaneously. Background work continues after the response is sent.

    Latency-based routing. With multi-region endpoints, each request routes to the nearest region automatically.

    Native streaming. SSE (server-sent events), chunked transfer, and request / response streaming built in for AI and real-time workloads.

     

    Direct control. You choose regions, endpoints, and traffic allocation across two revisions.

    Multi-region deployment in one command. Deploy once. Lambda Web Functions replicates your code to your chosen regions and handles latency-based routing.

    Automatic scaling. Scales from zero based on incoming requests. No resource provisioning required.

     

    Active compute billing. Billed per ms of active compute. I/O wait is not billed.

    Pay for memory used. Pay only for memory used with active execution environments.
     

Use Cases

Lambda Web Functions is built for HTTP workloads. Here are leading patterns where it fits.

    Full-stack JavaScript applications using React SSR, or framework-agnostic Node.js servers, that need consistent performance for global audiences.

    REST and GraphQL APIs built with web frameworks such as Express, Hono, or Fastify. Multi-concurrency handles bursty traffic without cold-start penalties, and active CPU billing cuts cost for I/O-heavy workloads waiting on databases.

    LLM gateway APIs that stream token responses via SSE or chunked transfer. Native request/response streaming supports large streamed payloads, and you can connect to AWS services like Bedrock using the standard AWS SDK.

    Applications that need fast, consistent response times for global user bases, such as real-time dashboards and interactive tools. Opt-in multi-region endpoints replicate your code and route each user to the nearest region by latency.

    Use a Lambda Web Function as a CloudFront origin for dynamic content that needs a full Node.js runtime, large deployment packages (up to 512 MB), and multi-concurrency, while CloudFront handles caching and static assets.

Using a coding agent?

Copy and paste the following instructions to give your agent the tools, knowledge, and guardrails it needs to work effectively with AWS Lambda.

bash
Set up your agent to build with AWS Lambda: 
https://docs.aws.amazon.com/lambda/latest/dg/samples/aws-lambda-agent-setup.md

  

Booking.com runs Node.js web apps on Lambda Web Functions

"Lambda Web Functions gives us a highly performant way to run our Node.js web applications that automatically scales to handle our peak traffic spikes. Running on a newer generation of faster compute with active CPU billing, we no longer pay for the time each request spends waiting on downstream services, only for the work being done. For our server-side rendering and API workloads we have lowered latency for our users. "

—Matt Crouch, Solutions Architect at Booking.com

Booking-Dot-Com Logo

Marketing Evolution cuts first-request latency 4x for its multi-agent platform

"We were building a multi-agent platform and our Python applications supporting our user chat service was experiencing high latency. We joined the Lambda Web Functions preview and rebuilt those services as Node.js Web Functions. We were excited to see a 4x improvement in our app performance that directly improved our users' experience. "

—Patrick Sabo, Principal AI & DevOps Engineer at Marketing Evolution

Missing alt text value

How much does Lambda Web Functions cost?

Lambda Web Functions are priced based on the number of requests served, active CPU time, consumed memory, and standard AWS data transfer.View detailed pricing

Did you find what you were looking for today?

Let us know so we can improve the quality of the content on our pages