Article version: Enterprise Server 2.13

This version of GitHub Enterprise will be discontinued on This version of GitHub Enterprise was discontinued on 2019-03-27. No patch releases will be made, even for critical security issues. For better performance, improved security, and new features, upgrade to the latest version of GitHub Enterprise. For help with the upgrade, contact GitHub Enterprise support.

Page build failed: Config file error

If the _config.yml file in your GitHub Pages repository has syntax errors, your GitHub Pages site will not build.

If your GitHub Pages site fails to build because the _config.yml file contains syntax errors, we'll send you an email that looks like this:

Subject: Page build failed

The page build failed with the following error:

You have an error on line 1 of your _config.yml file.

You will only receive an email if outbound email support is enabled on your Enterprise instance. For more information, contact your site administrator.

Troubleshooting _config.yml syntax errors

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

Check your _config.yml file at the line referenced in the build failure email. Ensure that:

Use a YAML linter, such as http://codebeautify.org/yaml-validator, to validate your YAML code. If you run into parse errors with your _config.yml file, try copying and pasting the contents of the file into such a tool for more details.

Once you've fixed any syntax errors in your _config.yml file, you will need to commit your changes and push to your GitHub Pages repository again to trigger another build on our servers.

Fixing highlighting errors

If you attempt to use a syntax highlighter other than Rouge on your GitHub Pages site with Jekyll, you'll receive a page build warning. GitHub Pages does not support other highlighters and will automatically use the default Rouge. For more information, see "Using syntax highlighting on GitHub Pages."

To fix page build warnings, you must change your highlighter value to rouge in your _config.yml file.

  1. On GitHub Enterprise, navigate to the main page of the repository.

  2. In your repository, browse to _config.yml.

  3. In the upper right corner of the file view, click to open the file editor.

    open file editor with edit icon

  4. Find the line that starts with highlighter: and change the value to rouge.

    Rouge highlighter value in config.yml

  5. At the bottom of the page, type a short, meaningful commit message that describes the change you made to the file. You can attribute the commit to more than one author in the commit message. For more information, see "Creating a commit with multiple co-authors."

    Commit message for your change

  6. Below the commit message fields, decide whether to add your commit to the current branch or to a new branch. If your current branch is master, you should choose to create a new branch for your commit and then create a pull request.

    Commit branch options

  7. Click Propose file change.

    Propose file change button

Further reading:

Ask a human

Can't find what you're looking for?

Contact us