Skip to article content
AAverho

Software architecture · Foundations

Right now, as you read this, millions of HTTP requests are crossing the planet — authorizing payments, streaming video, syncing health records, and keeping the world’s systems in conversation.

HTTP

The invisible protocol holding every distributed system together.

Foundation12 min readSoftware architecture

You will never see HTTP working. You only notice when it fails. That is exactly why architects need to understand it — HTTP is the boundary where independent systems meet, negotiate, and depend on each other.

Opening scene

One tap. Six systems. Under one second.

This is not a diagram of HTTP in theory — it is the journey of a single real request.

What you’ll learn

After completing this topic you will be able to:

  • Explain why HTTP exists as the default protocol of distributed systems
  • Trace a request through a realistic multi-service architecture
  • Read and interpret HTTP request and response messages
  • Recognize common architectural mistakes involving HTTP
  • Decide when HTTP is — and is not — the appropriate protocol
  • Describe HTTP's role as an architectural boundary between teams

01

The Problem

Imagine you are designing an online banking platform. A customer opens the mobile app and taps “Check Balance.” That single tap must travel from the phone, across the internet, through your backend infrastructure, reach the account database, and return the result — all in under a second.

Now imagine every system in that chain spoke a different language. The mobile app uses one protocol, the API gateway another, the account service a third. Every integration would require custom adapters, bespoke parsing logic, and endless debugging.

Before HTTP, this was the reality. Every application could invent its own communication protocol, making interoperability difficult and expensive. A web browser would need to understand countless proprietary methods, while servers would have to support many incompatible clients.

Think Like an Architect

As an architect, your job is to reduce coupling between systems. A standard protocol is one of the most powerful tools you have. When every service speaks the same language, you can replace, upgrade, or scale individual components without rewriting the communication layer.

HTTP gave the internet exactly that: a common language for requesting and delivering information.

Once you understand why a shared protocol matters, the next question is deceptively simple: what actually happens when two systems talk?

02

The Big Idea

Textbooks describe HTTP as a conversation between client and server. Real systems tell a different story — one request, passing through many architectural boundaries.

Visual landmark

Where HTTP lives inside a modern platform
Experience
Mobile AppWeb BrowserPartner API
Edge
CDNWAFLoad Balancer
Gateway
API GatewayAuth ProxyRate Limiter
Services
PaymentsAccountsNotifications
Data
Ledger DBCacheObject Store

A client asks for something.

A server responds.

The request–response model sounds simple. To architect with it, you need to see the machinery underneath.

03

How It Works

Every HTTP exchange follows the same lifecycle — a conversation with five distinct phases that repeat billions of times per day across the globe.

  1. 01ConnectTCP handshake established
  2. 02RequestClient sends method + URL + headers
  3. 03ProcessServer interprets and acts
  4. 04RespondServer returns status + body
  5. 05CloseConnection reused or released

A request typically contains

  • an HTTP method (GET, POST, PUT, DELETE…)
  • a URL identifying the resource
  • request headers
  • an optional request body

A response contains

  • a status code
  • response headers
  • an optional response body

Here is what that lifecycle looks like in practice — the same balance check from the opening scene, now as raw messages on the wire.

Client sends

HTTP request
GET /accounts/123 HTTP/1.1
Host: api.bank.com
Accept: application/json

Server replies

HTTP response
HTTP/1.1 200 OK
Content-Type: application/json

{
  "accountId": 123,
  "balance": 1500.75
}

Architect’s Question

If HTTP is stateless, how does your bank remember who you are after login?

Consider this

HTTP does not maintain sessions — your architecture must. Tokens in headers, cookies, or server-side session stores carry identity across requests. The protocol stays simple; the application owns the state.

Knowing how messages move is necessary. Seeing where HTTP sits in the system landscape is what separates implementers from architects.

Architecture Lens

Architecture Lens

HTTP is not just a protocol — it is an architectural boundary. Every HTTP call between services represents a contract that must be versioned, monitored, secured, and documented.

In distributed systems, the choice of protocol shapes how teams deploy, scale, and debug. HTTP-based services can be developed in different languages, deployed independently, and replaced without coordination — as long as the contract is preserved.

This is why HTTP remains the default choice for public APIs, microservice communication, and cloud-native architectures. It prioritizes interoperability over performance, which is exactly what you need when systems are owned by different teams, organizations, or continents.

04

When to Use It

HTTP is the default whenever independent systems need to communicate across a network. But defaults exist to be questioned — especially when latency, streaming, or async processing enter the picture.

Protocol
Best For
Trade-off
HTTP
Request–response APIs, web & mobile backends
Text overhead, stateless
gRPC
High-performance internal microservices
Binary, less human-readable
WebSocket
Real-time bidirectional communication
Stateful, more complex infra
Message Queue
Async event-driven processing
Eventual consistency, extra infra

Decision Point

Your team is building a payment API consumed by mobile apps, partner banks, and internal services. Latency targets are under 200ms. Would you choose HTTP, gRPC, or a message queue for the public API?

Choose HTTP when

  • Interoperability matters most
  • You need broad client support
  • Debugging and tooling are important
  • Your architecture is request–response

Consider alternatives when

  • You need sub-millisecond latency
  • Bidirectional streaming is required
  • Message brokering is needed
  • Bandwidth is extremely constrained

HTTP is the right public boundary. Mobile apps and partner banks need broad compatibility, debuggable messages, and standard tooling. gRPC or queues may serve internal paths — but the external contract should speak the language the ecosystem already understands.

Choosing HTTP is only the beginning. Every architectural choice carries trade-offs — and HTTP is no exception.

05

Trade-offs

HTTP became dominant because it balances simplicity, flexibility, and interoperability. But no protocol is free — understanding the cost is part of architectural maturity.

Advantages
Limitations
  • Universally supported across platforms
  • Human-readable and easy to debug
  • Stateless by design — scales horizontally
  • Easily cached at multiple levels
  • Firewall friendly (port 80/443)
  • Extensible through headers
  • Supported by virtually every language and framework
  • Request–response communication only
  • Additional overhead from headers
  • Text-based protocol (except HTTP/2 framing)
  • Statelessness requires external session management
  • Less efficient than binary protocols for high-performance internal communication
  • No built-in push mechanism

With trade-offs understood, the mistakes architects make become easier to spot — because they usually stem from misunderstanding what HTTP actually guarantees.

06

Common Mistakes

Treating HTTP as only “the web”

HTTP is the communication protocol for far more than websites. Modern APIs, cloud platforms, banking systems, IoT devices, and microservices all rely heavily on HTTP.

Ignoring HTTP semantics

Using POST for every operation or returning 200 OK for every outcome removes much of the protocol’s value. Correct methods and status codes make APIs predictable and easier to integrate.

Confusing HTTP with HTTPS

HTTP defines how messages are exchanged. HTTPS is HTTP running over TLS, providing encryption, integrity, and authentication. They are not interchangeable terms.

Assuming HTTP is stateful

Each request is independent. If applications require user sessions, authentication state, or shopping carts, that state must be managed outside the HTTP protocol itself.

Ignoring caching

Many APIs repeatedly calculate identical responses when HTTP caching mechanisms could significantly reduce latency and server load.

Theory and caution mean little without grounding. These are the systems where HTTP is not abstract — it is the daily infrastructure of real products.

07

Real-world Examples

System story

A payment authorization crossing six HTTP boundaries.

Six services. Six contracts. One protocol holding them together.

Online Banking

A mobile banking application requests an account balance. The request passes through an API gateway for authentication, reaches the accounts service, and queries the database — all over HTTP.

Mobile App → CDN → API Gateway → Accounts Service → Database
HTTP request
GET /accounts/123

Open Banking APIs

A licensed third-party provider requests transaction history using standardized HTTP endpoints secured with OAuth 2.0. The bank’s API gateway authenticates the request, retrieves the data, and returns it in a standard format.

Because every participant follows the HTTP specification, banks, fintech companies, and regulators can build interoperable systems without custom integrations.

Microservices

An Order Service calls an Inventory Service to verify stock availability before confirming a purchase. Each service is developed, deployed, and scaled independently — connected only by HTTP.

Although both services may be written in different programming languages and deployed independently, HTTP provides a common communication protocol between them.

Streaming at Scale

Could Netflix stream without HTTP? Not as we know it. Manifest requests, DRM licenses, and playback authorization all cross HTTP boundaries before a single frame reaches your screen.

Netflix, Spotify, and YouTube all rely on HTTP-based APIs for metadata, authentication, and content delivery orchestration — even when the video bytes travel over specialized protocols.

08

Key Takeaways

You began with a single tap on a banking app. You end here — with the architectural lens to see HTTP in every system you build.

  • HTTP is the standard communication protocol of the web — a universal language for distributed systems.
  • It defines how clients and servers exchange requests and responses, with no knowledge of each other’s implementation.
  • HTTP is stateless, extensible, and widely supported — these properties make it the default choice for most architectures.
  • Modern APIs, cloud platforms, and banking systems all rely heavily on HTTP as their communication backbone.
  • Understanding HTTP is foundational for software architecture because countless higher-level technologies build upon it.