Article version:

Page build failed: File is a symlink

If a file in your GitHub Pages repository references a symlinked file that does not exist in your repository, then your GitHub Pages site will not build.

If your GitHub Pages site fails to build because of a reference to a symlinked file, you'll get an email that looks like this:

Subject: Page build failed

The page build failed with the following error:

A file was included in `example.html` that is a symlink or does not exist in your `_includes` directory.

Troubleshooting a symlinked file error

Tip: We strongly recommend running Jekyll locally so you can easily debug and fix build errors before pushing to GitHub. To learn more about troubleshooting options, see "Troubleshooting GitHub Pages builds."

  1. Use your favorite text editor to open the file mentioned in the build failure email.
  2. Search for the include tag to see where you've referenced other files. For example: {% include cool_header.html %}.
  3. Copy or move any symlinked files into the _includes directory of your GitHub Pages repository.
  4. Commit and push to your GitHub Pages repository on GitHub to trigger another build on the server.

Ask a human

Can't find what you're looking for?

Contact us