This version of GitHub Enterprise will be discontinued on This version of GitHub Enterprise was discontinued on 2020-08-20. 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.

Article version: Enterprise Server 2.18

Enabling private mode

In private mode, GitHub Enterprise Server requires every user to sign in to access the installation.

Did this doc help you?

You must enable private mode if your GitHub Enterprise Server instance is publicly accessible over the Internet. In private mode, users cannot anonymously clone repositories over git://. If built-in authentication is also enabled, an administrator must invite new users to create an account on the instance. For more information, see "Using built-in authentication."

Warning: If you add an image attachment to a pull request or issue comment, anyone can view the anonymized image URL without authentication, even if the pull request is in a private repository, or if private mode is enabled. To keep sensitive images private, serve them from a private network or server that requires authentication.

With private mode enabled, you can allow unauthenticated Git operations (and anyone with network access to your GitHub Enterprise Server instance) to read a public repository's code on your instance with anonymous Git read access enabled. For more information, see "Allowing admins to enable anonymous Git read access to public repositories."

  1. In the upper-right corner of any page, click .
    Rocketship icon for accessing site admin settings
  2. In the left sidebar, click Management Console.
    Management Console tab in the left sidebar
  3. In the left sidebar, click Privacy.
    Privacy tab in the settings sidebar
  4. Select Private mode.
    Checkbox for enabling private mode
  5. Under the left sidebar, click Save settings.
    Save settings button

Did this doc help you?

Ask a human

Can't find what you're looking for?

Contact us