How can I deploy a simple static website using GitHub Pages?

Huzaifa Bin Tariq 20 Reputation points
2026-08-27T12:28:29.39+00:00

I have created a simple HTML, CSS, and JavaScript project and uploaded it to GitHub. I want to deploy it using GitHub Pages. What are the steps to enable GitHub Pages and make the website publicly accessible?

Azure Static Web Apps
Azure Static Web Apps

An Azure service that provides streamlined full-stack web app development.

0 comments No comments

Answer accepted by question author
Amaar Zaraar 80 Reputation points
2026-08-27T12:36:44.23+00:00

To deploy your website, open your repository on GitHub, click the Settings tab, and select Pages from the left sidebar. Under Build and deployment, change the Source to Deploy from a branch. Select your primary branch (usually main or master) from the dropdown menu, keep the folder as / (root), and click Save. Wait two minutes, refresh the page, and click the live link provided at the top.

Was this answer helpful?

1 person found this answer helpful.
0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.