NGINX FOR BEGINNERS
Understanding Reverse Proxy — Step-by-Step Tutorial
🎯 Audience: Complete Beginners | ⏱ Est. Runtime: ~18–22 mins
🎬 SECTION 1: Hook & Introduction
⏱ TIME: 0:00 – 1:30
On-Camera / Voice-Over
"Have you ever wondered how big websites handle millions of visitors without crashing? Or how
your browser reaches the right server when you type a URL? The answer — at least part of it —
is Nginx."
"Today, we're going to break down one of the most important concepts in web infrastructure: the
Reverse Proxy. And we're going to use Nginx to build one ourselves — from scratch — even if
you've never touched a server before."
📌 WHAT YOU'LL LEARN
What Nginx is and why it matters • What a Reverse Proxy is (in plain English) • How to
install Nginx • How to configure it as a Reverse Proxy • How to test that everything works
Screen Action
Show title card: "NGINX Reverse Proxy — Beginner's Guide"
Quick B-roll of terminal, browser, and a simple network diagram.
📘 SECTION 2: What Is Nginx?
⏱ TIME: 1:30 – 4:00
On-Camera / Voice-Over
"Nginx — pronounced 'engine-ex' — is a free, open-source web server. But calling it just a web
server is like calling a Swiss Army knife just a knife. Nginx can act as a web server, a load
balancer, a caching server, and — what we care about today — a reverse proxy."
"It was created in 2004 by Igor Sysoev to handle the C10K problem — serving 10,000
simultaneous connections. It's now used by Netflix, Airbnb, Dropbox, and millions of other sites."
Quick Analogy — Say This On Camera
💡 ANALOGY
"Think of Nginx like a hotel receptionist. When guests arrive, the receptionist doesn't take
them to every room themselves — they direct each guest to the right place. That's what
Nginx does with web traffic."
Screen Action
Show a simple diagram: Internet → Nginx → App Server (Node / Python / etc.)
Annotate: "Nginx sits in front of everything"
🔄 SECTION 3: What Is a Reverse Proxy?
⏱ TIME: 4:00 – 7:00
On-Camera / Voice-Over
"Let's talk about the star of today's tutorial: the Reverse Proxy."
"First — what's a regular proxy? A regular, or forward proxy, sits in front of clients. It hides the
user. For example, a VPN is a type of forward proxy."
"A Reverse Proxy is the opposite — it sits in front of servers. Instead of hiding the client, it hides
the server. From the outside, all the user sees is one address: your domain. Behind the scenes,
Nginx forwards that request to the right internal server."
🆚 FORWARD vs REVERSE PROXY
Forward Proxy → hides the CLIENT from the server (e.g. VPN) Reverse Proxy → hides the
SERVER from the client (e.g. Nginx in front of your app)
Why Should You Care?
Security — your app server is never exposed directly to the internet.
Flexibility — you can run multiple apps on one server, one domain.
Performance — Nginx handles SSL termination and caching for you.
Scalability — easily add more app servers behind Nginx later.
Screen Action
Animate a diagram: Client → Nginx (port 80) → App Server (port 3000)
Label each arrow. Pause on the diagram for 3–4 seconds.
⚙️SECTION 4: Installing Nginx
⏱ TIME: 7:00 – 9:30
On-Camera / Voice-Over
"Alright — enough theory. Let's get our hands dirty. I'm going to use Ubuntu Linux here, which is
the most common server environment you'll encounter."
"Open your terminal and run:"
# Update your package list
sudo apt update
# Install Nginx
sudo apt install nginx -y
# Start Nginx
sudo systemctl start nginx
# Enable it to start on boot
sudo systemctl enable nginx
# Verify it's running
sudo systemctl status nginx
"Now open your browser and go to [Link] — you should see the Nginx welcome page.
If you do: congratulations! Nginx is running."
✅ SUCCESS CHECK
Visit [Link] in your browser. You should see: "Welcome to nginx!" — if you do,
you're good to go!
Screen Action
Record terminal in real time — don't speed up.
Show browser opening and the Nginx welcome page.
SECTION 5: Configuring Nginx as a Reverse Proxy
⏱ TIME: 9:30 – 15:00
On-Camera / Voice-Over
"Now for the main event. We're going to configure Nginx to forward incoming requests to a
backend app. For this demo, our backend is a simple web app running on port 3000 — it could
be [Link], Python Flask, anything."
Step 1 — Start a Simple Backend App
"To simulate a backend, run this quick Python server:"
# Python 3 — runs a simple server on port 3000
python3 -m [Link] 3000
Step 2 — Create an Nginx Config File
"Nginx config lives in /etc/nginx/sites-available/. Let's create a new config for our site:"
sudo nano /etc/nginx/sites-available/myapp
"Now paste this configuration:"
server {
listen 80;
server_name localhost;
location / {
proxy_pass [Link]
proxy_http_version 1.1;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
Break Down Each Line — Say This On Camera
"Let me explain what each line does so this isn't just magic:"
listen 80; Nginx listens on port 80 — the standard HTTP port.
server_name localhost; Which domain or hostname this block applies to.
location /; Match all incoming URLs.
proxy_pass; Forward the request to our backend on port 3000.
proxy_set_header; Pass along important request info to the backend.
Step 3 — Enable the Config & Reload
# Link your config to sites-enabled
sudo ln -s /etc/nginx/sites-available/myapp /etc/nginx/sites-enabled/
# Test your config for syntax errors
sudo nginx -t
# Reload Nginx
sudo systemctl reload nginx
🔑 PRO TIP
Always run 'sudo nginx -t' before reloading. It checks for typos in your config. A syntax error
here can take down your whole site!
Screen Action
Show nano editor with the config clearly visible — zoom in if needed.
Run each command one at a time. Narrate what you're doing.
Show terminal output of 'nginx -t': look for 'syntax is ok' and 'test is successful'.
✅ SECTION 6: Testing Your Reverse Proxy
⏱ TIME: 15:00 – 17:30
On-Camera / Voice-Over
"The moment of truth. With your Python backend running on port 3000 and Nginx running on
port 80, open your browser and go to [Link]
"What you should see is the content from your Python server — but you didn't access port 3000
directly. Nginx intercepted your request on port 80 and forwarded it. That's your reverse proxy
working!"
"You can also test it from the terminal using curl:"
# Test the proxy from terminal
curl -I [Link]
# You should see: HTTP/1.1 200 OK
# And response headers from Nginx
🧪 WHAT TO VERIFY
1. Browser at [Link] shows backend content 2. Port 3000 is NOT directly exposed
(try [Link] from a different machine — it should fail) 3. 'curl -I [Link]
returns 200 OK
Screen Action
Show browser side-by-side: [Link] (through Nginx) vs [Link] (direct).
Highlight: same content, different ports — Nginx is the middleman!
🎤 SECTION 7: Wrap-Up & Next Steps
⏱ TIME: 17:30 – End
On-Camera
"And that's it! In just a few minutes, you've installed Nginx and configured it as a reverse proxy.
You now understand one of the foundational building blocks of modern web infrastructure."
"Here's a quick recap of what we covered:"
What Nginx is and why it's widely used
The difference between a forward proxy and a reverse proxy
How to install Nginx on Ubuntu
How to write an Nginx reverse proxy config file
How to enable, reload, and test your configuration
Call to Action
📣 SAY THIS DIRECTLY TO CAMERA
"If this helped you, hit Like and Subscribe — it helps a lot. Drop a comment below if you got
stuck anywhere and I'll help you out. Next video: we'll add SSL/HTTPS to this setup using
Let's Encrypt, so stay tuned."
Suggested Next Videos — Show On Screen
➡️ Adding HTTPS to Nginx with Let's Encrypt (Free SSL)
➡️ Nginx Load Balancing — Beginner Tutorial
➡️ Deploy a [Link] App Behind Nginx on a VPS
🎥 PRODUCTION NOTES
Pacing & Delivery
Speak at 80% of your normal speed — beginners need processing time.
Pause for 2 seconds after every command before moving on.
Don't skip errors — if something goes wrong on screen, keep it in and fix it live.
B-Roll / Graphics Suggestions
Animated diagram: Client → Nginx → App Server (use a tool like Excalidraw or Canva)
Terminal font size: at least 18pt — viewers watch on phones too.
Highlight the [Link] block with a colored overlay when explaining each line.
Chapter Markers for YouTube
0:00 - Introduction & Hook
1:30 - What Is Nginx?
4:00 - What Is a Reverse Proxy?
7:00 - Installing Nginx
9:30 - Configuring Nginx as a Reverse Proxy
15:00 - Testing Your Setup
17:30 - Recap & Next Steps
— END OF SCRIPT —