LearnThatStack Ace your next interview
Computer Science Fundamentals

Networking for Developers.

Start free Change topic Change

Practise Networking for Developers one question at a time. Answer out loud or in writing, get graded, and see exactly what you missed.

Try one question

What happens when you type a URL into a browser and hit Enter?

The answer

The browser finds the server, asks it for the page, and renders what comes back, in a fixed sequence of small steps.

  • It parses the URL into scheme, host and path.
  • It resolves the hostname into an IP address through DNS.
  • It opens a TCP connection to that server on the right port. For HTTPS, a TLS handshake then sets up encryption.
  • It sends an HTTP request for the path. The server replies with a status code and usually an HTML body.
  • It parses the HTML and fetches the stylesheets, scripts and images it finds, often over the same connection. Then it renders the page.

Each step adds delay, so a slow page usually has one clear culprit, and knowing the sequence tells you where to look first.

Example · what grading looks like
How does DNS turn a website hostname into an IP address?

“So first the browser checks if it already knows the address, since the browser and the OS both keep a cache. If not, it asks a recursive resolver, usually the ISP's or a public one like 8.8.8.8. On a miss the resolver walks down the hierarchy: a root server tells it who handles .com, the .com server tells it which nameserver is authoritative for that domain, and the authoritative server gives back the actual IP. The resolver caches that answer for the record's TTL and hands it back, and then the browser can open the connection.”

Knew it

Covers the browser/OS cache check, resolver hierarchy from root to TLD to authoritative server, and TTL caching. Doesn't mention that this lookup adds latency on the critical path before the real request starts.

Missed: Doesn't note that this lookup happens before the actual request and adds real latency on a cache miss


Get your own answers graded

Sign up free. Your account comes with 50 credits for grading, and it remembers what you missed.

What it covers

All 51 questions

Each on its own page

Layers, addresses and URLs

How a request gets from a typed URL to a process on a server: network layers, IP addresses, ports, sockets and URL parts.

5 questions

  1. What happens when you type a URL into a browser and hit Enter?
  2. What is a socket, and what does it represent to your program? Pro
  3. What is an IP address, and how does a port identify a process? Pro
  4. What are the parts of a URL, and what does each part control? Pro
  5. What is the OSI model, and how does it map to the TCP/IP model? Pro

DNS resolution

How hostnames become IP addresses: resolvers, record types, caching and TTL, and why DNS runs on UDP with a TCP fallback.

4 questions

  1. How does DNS turn a website hostname into an IP address?
  2. How do DNS caching and TTL affect how fast record changes propagate? Pro
  3. What are the common DNS record types, and what is each used for? Pro
  4. Why does DNS use UDP, and when does it fall back to TCP? Pro

TCP and UDP transport

TCP versus UDP, and how TCP opens, delivers reliably and in order, applies flow control and closes a connection.

5 questions

  1. What is the difference between TCP and UDP, and when do you use each?
  2. What is the TCP three-way handshake, and why does it exist?
  3. How does TCP guarantee reliable, in-order delivery of a byte stream? Pro
  4. How does a TCP connection close gracefully, and what is the FIN exchange? Pro
  5. How does TCP flow control use the receive window to apply backpressure? Pro

HTTP methods and status codes

What each HTTP method does, safe versus idempotent methods, choosing PUT, PATCH or POST, and what status codes and redirects mean.

5 questions

  1. What are the common HTTP methods, and what does each one do?
  2. What do the 2xx, 3xx, 4xx, and 5xx status code families mean?
  3. What makes an HTTP method safe versus idempotent, and why does it matter? Pro
  4. When do you use PUT versus PATCH versus POST for updates? Pro
  5. What is the difference between a 301 and a 302 redirect? Pro

Cookies, sessions and caching

How stateless HTTP keeps users logged in with cookies, which cookie attributes protect sessions, and how browser caching revalidates.

4 questions

  1. What is a cookie, and how does a server use it across requests? Pro
  2. How does browser caching work with Cache-Control, ETag, and revalidation? Pro
  3. What do the Secure, HttpOnly, and SameSite cookie attributes each protect against? Pro
  4. HTTP is stateless, so how do applications keep users logged in? Pro

TLS and HTTPS

What HTTPS adds over HTTP, the TLS handshake, how certificate chains are verified, and what TLS 1.3 and 0-RTT change.

4 questions

  1. What is the difference between HTTP and HTTPS, and why does it matter?
  2. What are the steps of a TLS handshake, and what does each achieve? Pro
  3. How does a client verify a server's TLS certificate and its chain? Pro
  4. What does TLS 1.3 change, and why is 0-RTT resumption risky? Pro

HTTP versions and multiplexing

Head-of-line blocking in HTTP/1.1, how HTTP/2 multiplexes streams yet still stalls on TCP, and how HTTP/3 over QUIC fixes it.

4 questions

  1. What is head-of-line blocking, and how does it hurt HTTP/1.1? Pro
  2. How does HTTP/2 improve on HTTP/1.1 for real web applications? Pro
  3. How does HTTP/2 multiplexing still suffer from TCP head-of-line blocking? Pro
  4. How does HTTP/3 use QUIC over UDP to solve that blocking? Pro

Real-time and streaming

Pushing data as it happens: WebSocket upgrades, Server-Sent Events, long polling and chunked responses of unknown length.

3 questions

  1. How does a WebSocket connection upgrade from an ordinary HTTP request? Pro
  2. How do WebSockets, Server-Sent Events, and long polling compare for real-time updates? Pro
  3. How does chunked transfer encoding stream a response of unknown length? Pro

Connection reuse and pooling

Keep-alive and connection pools, sizing a pool, the stale keep-alive race, and how TIME_WAIT and connection churn exhaust ports.

6 questions

  1. What is HTTP keep-alive, and why do persistent connections matter? Pro
  2. Why does connection pooling matter, and what cost does it save? Pro
  3. What is TCP TIME_WAIT, and how can it exhaust ports at scale? Pro
  4. How does ephemeral port exhaustion happen under heavy outbound connection churn? Pro
  5. What race occurs when a client reuses a keep-alive connection the server just closed? Pro
  6. How do you size a connection pool, and what breaks when it saturates? Pro

Latency and TCP performance

Latency versus bandwidth, round-trip costs, slow start, Nagle and delayed ACK, bandwidth-delay product, MTU, and finding a slow phase.

7 questions

  1. What is the difference between latency and bandwidth, and why does it matter? Pro
  2. How does round-trip time shape the cost of opening a new HTTPS connection? Pro
  3. How does TCP slow start throttle throughput at the start of a connection? Pro
  4. How do Nagle's algorithm and delayed ACK combine to add surprising latency? Pro
  5. What is the bandwidth-delay product, and why does it cap throughput on long links? Pro
  6. How do MTU and MSS affect large transfers, and what is path MTU discovery? Pro
  7. How do you diagnose a slow request across DNS, TCP, TLS, and server time? Pro

Retries, timeouts and resilience

Making clients survive failure: idempotency keys, backoff with jitter, connect versus read timeouts, and preventing cache stampedes.

4 questions

  1. How do you make a non-idempotent request safe to retry? Pro
  2. How do you design retries with backoff and jitter to avoid retry storms? Pro
  3. How do connect timeouts and read timeouts differ, and how do you pick them? Pro
  4. How does a cache stampede happen, and how do you prevent it? Pro
Practice · Questions

All questions

Showing of 51
Beginner 13
01

What happens when you type a URL into a browser and hit Enter?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

The browser finds the server, asks it for the page, and renders what comes back, in a fixed sequence of small steps.

  • It parses the URL into scheme, host and path.
  • It resolves the hostname into an IP address through DNS.
  • It opens a TCP connection to that server on the right port. For HTTPS, a TLS handshake then sets up encryption.
  • It sends an HTTP request for the path. The server replies with a status code and usually an HTML body.
  • It parses the HTML and fetches the stylesheets, scripts and images it finds, often over the same connection. Then it renders the page.

Each step adds delay, so a slow page usually has one clear culprit, and knowing the sequence tells you where to look first.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

02

How does DNS turn a website hostname into an IP address?

Visual

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain
Visual

Your machine asks a resolver, which answers from its cache or walks the DNS hierarchy down to the server that owns the name. The resolver is usually run by your ISP or a public service. DNS works like a phone book that maps names to addresses.

On a cache miss, the resolver starts at a root server, which points to the top-level domain server for .com. That server points to the authoritative server for the domain. The authoritative server returns the actual IP address, and the resolver hands it back to your program.

The lookup happens before any real request, so it sits on the critical path. A cold lookup can add tens of milliseconds. Caching along the way keeps most lookups fast.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

03

What is the difference between TCP and UDP, and when do you use each?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

TCP gives you a reliable, ordered stream, while UDP gives you fast, best-effort messages. TCP sets up a connection, tracks every byte and resends lost data. It delivers bytes in order, so what you send arrives whole.

UDP just fires packets with no handshake and no retries. Packets can arrive late, out of order, or not at all. In exchange it has almost no overhead and lower latency.

Reach for TCP when correctness matters, as in web pages and APIs. File transfers and databases need it too. Reach for UDP when speed beats completeness, as in live video and voice calls. Games and DNS lookups use it for the same reason. Losing one frame of video beats stalling the whole stream.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

04

What are the common HTTP methods, and what does each one do?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

An HTTP method tells the server what action you want on a resource, and each request names one method up front.

  • GET fetches a resource without changing it.
  • POST submits data, often to create something new.
  • PUT replaces a resource with the body you send.
  • PATCH updates part of a resource.
  • DELETE removes the named resource.
  • HEAD fetches only the headers, no body.

The choice matters because caches, proxies and browsers treat methods differently. A GET can be cached and prefetched, but a POST usually cannot. The wrong one causes surprising behavior and confuses anyone reading your API.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

05

What do the 2xx, 3xx, 4xx, and 5xx status code families mean?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

The first digit of a status code names its family, which says whether the request worked and who is at fault. You can react to the family before reading the exact code.

  • 2xx is success, like 200 OK or 201 Created.
  • 3xx is a redirect, used when the resource moved or has not changed.
  • 4xx is a client error, like 404 Not Found or 401 Unauthorized.
  • 5xx is a server error on a valid request.

The family guides retries and blame. Resending a 4xx rarely helps, but a retry after a 5xx often works, since the fault sits on the server.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

06

What is the difference between HTTP and HTTPS, and why does it matter?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

HTTPS is plain HTTP wrapped inside an encrypted TLS connection. HTTP sends everything as readable text over the wire. HTTPS scrambles it, so anyone in between sees only noise.

The TLS layer does three jobs. It hides the content from eavesdroppers. It proves you reached the real server, not an impostor. It detects any tampering with the bytes in transit.

This matters because networks are full of untrusted hops, such as coffee-shop WiFi, ISPs and proxies. Without HTTPS, passwords and cookies travel in the clear. Browsers now mark plain HTTP pages as not secure, so HTTPS is the default. That is why login pages and payment forms always use it.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

07

What is the TCP three-way handshake, and why does it exist?

Beginner ·

Answer it yourself first - out loud, or typed below.

How should your speech become text?

Listening… your words appear above as you speak - tap Stop when you're done.

Recording · cr - tap Stop & transcribe when you're done.

Transcribing with AI…

Voice:

Keep going - a few more words and AI can grade it.

Last attempt -

Your answer

Re-explain

The three-way handshake is how two machines agree to start a TCP connection. It takes three messages before any real data flows. Both sides pick a starting sequence number and confirm they can hear each other.

client -> SYN     (let's talk, my seq = x)
server -> SYN-ACK (ok, my seq = y, got your x)
client -> ACK     (got your y, let's go)

SYN means synchronize and ACK means acknowledge. The client's SYN proposes its own starting number. The server's SYN-ACK accepts that number and proposes its own. The final ACK confirms the server's number, so both sides agree.

It exists because TCP promises ordered, reliable delivery, and that promise needs both sides to sync sequence numbers first. The handshake also confirms the path works in both directions. The cost is one round trip of delay before you send data.

Rewriting in plainer words…

This answer doesn't lend itself to a diagram - it reads best . No credits were charged.

Why there's no diagram: “”

The interactive diagram is below the answer - jump to diagram ↓ · Below it, the related concept . Jump to it ↓

Related concept

Tailored explanation · switch back to · ·
What should the new diagram focus on?
How well did you know this?
AI:

08

What is a socket, and what does it represent to your program?

Part of Pro
09

What is the difference between latency and bandwidth, and why does it matter?

Part of Pro
10

What is an IP address, and how does a port identify a process?

Part of Pro
11

What is a cookie, and how does a server use it across requests?

Part of Pro
12

What are the parts of a URL, and what does each part control?

Part of Pro
13

What is the OSI model, and how does it map to the TCP/IP model?

Part of Pro
Intermediate 20
14

What makes an HTTP method safe versus idempotent, and why does it matter?

Part of Pro
15

When do you use PUT versus PATCH versus POST for updates?

Part of Pro
16

How does TCP guarantee reliable, in-order delivery of a byte stream?

Part of Pro Visual
17

How does a TCP connection close gracefully, and what is the FIN exchange?

Part of Pro
18

What are the steps of a TLS handshake, and what does each achieve?

Part of Pro
19

What is HTTP keep-alive, and why do persistent connections matter?

Part of Pro
20

What is head-of-line blocking, and how does it hurt HTTP/1.1?

Part of Pro Visual
21

How does HTTP/2 improve on HTTP/1.1 for real web applications?

Part of Pro Visual
22

How does browser caching work with Cache-Control, ETag, and revalidation?

Part of Pro
23

What do the Secure, HttpOnly, and SameSite cookie attributes each protect against?

Part of Pro
24

Why does connection pooling matter, and what cost does it save?

Part of Pro
25

How do DNS caching and TTL affect how fast record changes propagate?

Part of Pro Visual
26

What are the common DNS record types, and what is each used for?

Part of Pro
27

How does round-trip time shape the cost of opening a new HTTPS connection?

Part of Pro Visual
28

What is the difference between a 301 and a 302 redirect?

Part of Pro
29

How does a client verify a server's TLS certificate and its chain?

Part of Pro Visual
30

Why does DNS use UDP, and when does it fall back to TCP?

Part of Pro
31

HTTP is stateless, so how do applications keep users logged in?

Part of Pro
32

How does a WebSocket connection upgrade from an ordinary HTTP request?

Part of Pro
33

How do WebSockets, Server-Sent Events, and long polling compare for real-time updates?

Part of Pro
Expert 18
34

How does HTTP/2 multiplexing still suffer from TCP head-of-line blocking?

Part of Pro Visual
35

How does HTTP/3 use QUIC over UDP to solve that blocking?

Part of Pro Visual
36

What does TLS 1.3 change, and why is 0-RTT resumption risky?

Part of Pro
37

How does TCP slow start throttle throughput at the start of a connection?

Part of Pro Visual
38

How do Nagle's algorithm and delayed ACK combine to add surprising latency?

Part of Pro Visual
39

What is TCP TIME_WAIT, and how can it exhaust ports at scale?

Part of Pro Visual
40

How does ephemeral port exhaustion happen under heavy outbound connection churn?

Part of Pro
41

What is the bandwidth-delay product, and why does it cap throughput on long links?

Part of Pro Visual
42

How does chunked transfer encoding stream a response of unknown length?

Part of Pro
43

How do you make a non-idempotent request safe to retry?

Part of Pro Visual
44

How do you design retries with backoff and jitter to avoid retry storms?

Part of Pro Visual
45

How do connect timeouts and read timeouts differ, and how do you pick them?

Part of Pro Visual
46

What race occurs when a client reuses a keep-alive connection the server just closed?

Part of Pro Visual
47

How do you size a connection pool, and what breaks when it saturates?

Part of Pro
48

How does a cache stampede happen, and how do you prevent it?

Part of Pro Visual
49

How does TCP flow control use the receive window to apply backpressure?

Part of Pro Visual
50

How do MTU and MSS affect large transfers, and what is path MTU discovery?

Part of Pro Visual
51

How do you diagnose a slow request across DNS, TCP, TLS, and server time?

Part of Pro Visual

No matches

Try a different filter or search term.

Know someone prepping for Networking for Developers? Send them this set.
Quick recap

Networking for Developers in pictures.

A quick recap of Networking for Developers in 30 short animated pictures, one idea at a time. About 8 min to get the whole topic back in your head before you walk in. Pause any picture, slow it down, or step through it.

Pro The first chapter is free to play. The other 26 pictures come with Pro.

Get Pro · $10/mo
Pro · $10/mo

44 of 51 Networking for Developers answers are in Pro.

Full answers, code samples, and AI explanations that go simpler or deeper. Cancel anytime.

  • Full answers + code
  • AI explanations, simpler or deeper
  • 1,000 AI credits / month
  • Cancel anytime

Change topic

Pick a different technology or stack. Your current topic stays put until you choose a new one.

Technologies
No technologies match “”.
Cross-cutting topics
No topics match “”.
By role
Stacks & frameworks

MEAN

MongoDB, Express, Angular, Node.js

MERN

MongoDB, Express, React, Node.js

LAMP

Linux, Apache, MySQL, PHP

Django

Python Full-Stack Development

Ruby on Rails

Convention over Configuration

Serverless on AWS

Serverless Architecture on AWS

Flutter Mobile

Flutter Cross-Platform Mobile Development

Spring Boot

Enterprise Java Development

.NET

Microsoft Ecosystem

Vue

Vue.js, Vite, TypeScript, Tailwind, Node.js

Go Backend

Golang, gRPC, PostgreSQL, Redis, RabbitMQ

FastAPI

Python, FastAPI, SQLAlchemy, PostgreSQL

React Native

React, TypeScript, Redux, Firebase

iOS Native

Swift, SwiftUI, UIKit, Firebase

Android Native

Java, Jetpack Compose, Firebase

DevOps / Platform

Docker, Kubernetes, Terraform, CI/CD

AI Engineer

LLMs, RAG, Agents, Evals

AI-Powered Developer

Claude Code, Copilot, Agentic Workflows

Core SWE Interview Prep

Data structures, algorithms, OS, concurrency, networking, git