Serksa
All Concepts
API & Backend

Client vs Server

1

What is it?

A <strong>client</strong> is the one who asks for something, and a <strong>server</strong> is the one who provides it. In web applications, your browser (client) asks for web pages, and a server sends them back.

2

Think of it like...

The Customer and Shop Owner

Just like a customer asks a shop owner for products, a client asks a server for data or services.

👤

Client

Asks for things

🏪

Server

Provides things

📦

Response

What you get back

3

Visual Flow

💻Your Browser

Client

🌐Request

Asking for data

🖥️Web Server

Sends response

4

Where you see it

1

Client Makes Request

You type a URL or click a link in your browser

2

Request Travels

Your request goes over the internet to the server

3

Server Processes

The server finds what you asked for

4

Server Responds

The server sends back the data (HTML, images, etc.)

5

Client Displays

Your browser shows you the web page

5

Common Mistake

Wrong

The client and server are physical computers in different locations

Correct

Client and server are roles. Your laptop can be both a client (when browsing) and a server (when running a local server). It's about who's asking vs who's answering.

💡 Real-World Example

When you check Instagram:

1

Your phone (client) asks Instagram's servers for your feed

2

Instagram's server finds your personalized posts

3

Server sends back the data

4

Your phone displays the feed

5

Every like, comment, or scroll is a new request from client to server