Project 5: GitHub Pages – Netflix Landing Page with Nginx

Project 5: GitHub Pages – Netflix Landing Page with Nginx

Host the Netflix landing page free on GitHub Pages — no server to manage, just push and share the link.

Part 5 of 12 — 12 Hands-On AWS Projects

Introduction

In Project 4, we ran the Netflix landing page on an EC2 instance with Nginx. That worked, but the server keeps running — and a running server costs money. Today we will host the same page for free, with no server to manage at all. We will push our Netflix UI files to GitHub and switch on GitHub Pages. In a few minutes, anyone with the link can open our page in a browser.
This is the simplest way to put a website on the internet, and it is a skill you will use again and again for portfolios, demos and practice projects.

What you will build

  • A Netflix-style landing page built with plain HTML, CSS and JavaScript
  • A GitHub repository holding all the page files
  • A live public URL for your page, hosted free on GitHub Pages
  • A simple workflow you can reuse for any static website
  • The habit of versioning your work with Git from day one

Architecture

Your laptop holds the Netflix UI files. GitHub Desktop pushes them to a GitHub repository. GitHub Pages takes the files from the main branch and serves them as a live website. Visitors open the public URL and see your page — no EC2 instance, no server to run or patch.
Architecture diagram: your laptop holds the Netflix UI files, GitHub Desktop pushes them to a GitHub


Prerequisites

  • A GitHub account (free)
  • GitHub Desktop installed on your laptop (free)
  • Your Netflix UI files from Project 4 — index.html, style.css and script.js
  • A web browser and an internet connection

Steps

1. Prepare your Netflix UI files

Keep all the page files in one folder on your laptop. Name the main file index.html — GitHub Pages looks for this file first. Put your CSS file and JavaScript file in the same folder, and check the page opens correctly by double-clicking index.html in your browser.

2. Create a repository on GitHub

Open github.com and create a new repository. Name it netflix-ui. Keep it public so GitHub Pages can serve it for free, and do not add a README yet — we will push our own files in the next step.

3. Push the files using GitHub Desktop

Open GitHub Desktop and clone the netflix-ui repository to your laptop. Copy your Netflix UI files into the cloned folder. In GitHub Desktop you will see the new files listed — write a short summary like "Add Netflix landing page", click Commit, then click Push origin. Your files are now on GitHub.
You can also do the same from the command line:
git clone https://github.com/<username>/netflix-ui.git
cd netflix-ui
git add .
git commit -m "Add Netflix landing page"
git push origin main

4. Enable GitHub Pages

On GitHub, open your repository and go to Settings, then Pages. Under Build and deployment, choose Deploy from a branch. Select the main branch and the / (root) folder, then click Save. GitHub will take a minute or two to build your site.

5. Open your live page

Once the page shows a green message saying your site is live, open the URL in your browser:
https://<username>.github.io/netflix-ui/
Replace <username> with your GitHub username. You should see your Netflix landing page, live on the internet. Share the link with a friend and ask them to open it — that is the real test.

What you learned

  • GitHub Pages hosts static websites for free — HTML, CSS and JavaScript only, no server needed
  • GitHub Desktop makes pushing code simple, even if you are new to Git
  • The main branch and the root folder are what GitHub Pages serves by default
  • Your page gets a public URL in the form <username>.github.io/<repo-name>/
  • Every push to the main branch updates the live site automatically

Cleanup

There is nothing to delete here, and that is the beauty of this project. GitHub Pages hosting for a public repository is free, and there is no running server to stop. If you want to take the page down later, just delete the repository or turn off Pages in Settings.

Try next

In Project 6, we will take the same Netflix page and run it inside a Docker container with Nginx. You will build your own image, push it to DockerHub and run it anywhere with one command.


About Cloud Messenger — Learn • Build • Visualize • Troubleshoot • Grow | cloudmessenger.in | linkedin.com/in/cloud-messenger | github.com/Cloud-Messenger | #buildwithCloudMessenger
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article