Skip to content
/ deploy-github-pages Public template

Next.js template to deploy to GitHub Pages as a static site.

Notifications You must be signed in to change notification settings

nextjs/deploy-github-pages

Repository files navigation

Deploy Next.js to GitHub Pages

This is a Next.js template which can be deployed to GitHub Pages as a static site.

Deploying to GitHub Pages

  1. Create a new public GitHub repository
  2. Push the starter code to the main branch
  3. On GitHub, go to Settings > Pages > Source, and choose GitHub Actions as the source
  4. Make a commit and push it to see the changes on GitHub Pages

Congratulations! You should have a URL like:

https://<github-user-name>.github.io/<github-project-name>/

For more information, see our deployment documentation.

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!