What Serverless Is
TL;DR
Serverless means the platform starts your code to handle work and can stop it when the work is done. The machines still exist. You do not keep a server process running yourself.
What you run
What you skip
Idle behavior
Serverless is a way to run code where the platform starts an instance to handle work and can stop that instance when it is idle. You do not keep a server process running yourself. The machines are still there. You do not patch them, choose their size one by one, or leave them on overnight.
The usual trigger is an HTTP request or an event. The platform runs your handler and may freeze or destroy that instance after the response. A process that binds a port and waits is a different hosting model.
What you give the platform
You give it a function, a handler, or a small container, and you accept limits on memory, run time, and concurrency. You do not call listen() and wait for the next connection. The platform invokes you.
This handler does not open a port. The platform calls handler when a request arrives and takes the response back. A process that stays up and calls listen() is described under API hosting.
Cold starts and scale to zero
The first request after idle pays for startup. The platform finds capacity, starts a runtime, and loads your code. A later request on that same instance skips that work. The pause is a cold start. How long it is depends on the runtime, the size of the code, and the platform. There is no single number.
Scale to zero means no instance is kept while traffic is absent, so the next request is often cold. Keeping a minimum of one instance removes that pause for the next call, and it means you are paying for an idle worker again. That minimum is a setting. It does not change the definition. The platform can still stop extra instances it started for a spike.
State
Any instance may handle the next request, and the instance may disappear between requests. Local disk on that instance is temporary. Put durable data in a database or another service.
A stateless handler fits. An in-memory cache on the instance can still help while that instance lives. It is empty after a cold start, so you cannot treat it as the only copy of anything.
How this differs from a server you keep
Containerization packages a process you can run for days. Horizontal scaling adds more of those processes. Autoscaling is the loop that adds and removes capacity. Serverless platforms include that loop, and the floor is often zero. A container service can autoscale too, and still keep a process listening the whole time.
Idle cost follows the platform's prices. Many serverless platforms charge for execution time and requests rather than for a machine that sits idle. A steady, busy API can cost more that way than a small process that stays up. Compare the two with your traffic, your cold-start budget, and the published prices. There is no universal cutoff.
When it fits
Serverless fits work that can finish and then stop.
- Traffic that is rare or spiky, where an always-on machine would sit idle.
- A job with a clear end: resize an image, handle one webhook delivery, run a scheduled task.
- A small HTTP handler whose callers can tolerate a cold start, or where you pay for a minimum instance to avoid one.
It fits poorly when the latency budget cannot absorb startup, when the code depends on a warm cache or a warm connection pool, or when a request must run longer than the platform allows. Read that maximum before you move a workload. It is a product limit, and products differ. A connection that must stay open, such as a websocket, needs a platform that documents that mode. Even then, the connection usually has a time limit. Long polling has the same constraint: it assumes something is willing to hold the request.
What serverless does not remove
You still choose a region, handle timeouts, and limit concurrency. The platform can start instances faster than a database can accept connections. A rate limit in front of a scarce dependency still matters. Serverless removes the work of keeping a server on. It does not remove capacity planning.
The CNCF Serverless Whitepaper is a longer definition of functions and the backends they call. It is a 2018 overview, not a promise about any current product.
Questions & Answers about Serverless
Serverless is a way to run code where the platform starts an instance for the work and can stop it when the instance is idle. You do not provision a server and leave it on. The servers still exist. Someone else runs them, and you accept that platform's limits on duration, memory, and concurrency.
