How to fix 'hugo serve': Page Not Found

Problem

When running hugo serve and opening http://localhost:1313 in your browser, you encounter a “Page Not Found” error.

Hugo Page Not Found

Solution

Almost always, this issue is caused by a missing theme folder!

First, check if you forgot to update your submodules (if you already have a theme, but doesn’t hurt trying it in any case):

git submodule update --init

If that still doesn’t help, check if you’ve added a theme at all - see Step 3 of the the Quickstart. Also, check the output of hugo serve for any error messages!