The State of Docs Report 2025 is live! Dive in and see why docs matter more than ever:
Read the report
LogoLogo
ProductPricingLog inSign up
  • Documentation
  • Developers
  • Guides
  • Changelog
  • Help Center
  • Getting Started
    • GitBook Documentation
    • Quickstart
    • Importing content
    • GitHub & GitLab Sync
      • Enabling GitHub Sync
      • Enabling GitLab Sync
      • Content configuration
      • GitHub pull request preview
      • Commit messages & Autolink
      • Monorepos
      • Troubleshooting
  • Creating Content
    • Formatting your content
      • Inline content
      • Markdown
    • Content structure
      • Spaces
      • Pages
      • Collections
    • Blocks
      • Paragraphs
      • Headings
      • Unordered lists
      • Ordered lists
      • Task lists
      • Hints
      • Quotes
      • Code blocks
      • Files
      • Images
      • Embedded URLs
      • Tables
      • Cards
      • Tabs
      • Expandable
      • Stepper
      • Drawings
      • Math & TeX
      • Page links
    • Reusable content
    • Broken links
    • Searching content
      • Search & Quick find
      • GitBook AI
    • Writing with GitBook AI
    • Version control
  • API References
    • OpenAPI
      • Add an OpenAPI specification
      • Insert API reference in your docs
    • Guides
      • Structuring your API reference
      • Adding custom code samples
      • Managing API operations
      • Describing enums
      • Integrating with CI/CD
  • Extensions reference
  • Publishing Documentation
    • Publish a docs site
      • Public publishing
      • Private publishing with share links
    • Site structure
      • Content variants
      • Site sections
    • Site customization
      • Icons, colors, and themes
      • Layout and structure
      • Extra configuration
    • Set a custom domain
    • Setting a custom subdirectory
      • Configuring a subdirectory with Cloudflare
      • Configuring a subdirectory with Vercel
    • Site settings
    • Site insights
    • Site redirects
    • Visitor authentication
      • Enabling visitor authentication
      • Setting up Auth0
      • Setting up Azure AD
      • Setting up AWS Cognito
      • Setting up Okta
      • Setting up OIDC
      • Setting up a custom backend
  • LLM-ready docs
  • Collaboration
    • Live edits
    • Change requests
    • PDF export
    • Inviting your team
    • Comments
    • Notifications
  • Integrations
    • Install and manage integrations
    • GitHub Copilot
  • Account management
    • Plans
      • Legacy pricing
      • Sponsored site plan
      • Non-profit plan
      • Billing policy
    • Subscription cancellations
    • Personal settings
    • Organization settings
    • Member management
      • Invite or remove members
      • Roles
      • Teams
      • Permissions and inheritance
    • SSO & SAML
      • SSO Members vs non-SSO
  • Resources
    • GitBook UI
    • Keyboard shortcuts
    • Glossary
Powered by GitBook
On this page
  • I have a GitHub sync error
  • ​GitBook is not using my docs folder
  • GitBook is creating new markdown files
  • ​My repository is not listed
  • For GitHub repositories
  • For GitLab repositories
  • ​Nothing happens on GitBook after adding a new file to my repository
  • GitHub preview is not showing
  • Potential duplicated accounts when signing in

Was this helpful?

Edit on GitHub
  1. Getting Started
  2. GitHub & GitLab Sync

Troubleshooting

Last updated 5 months ago

Was this helpful?

LogoLogo

Resources

  • Showcase
  • Enterprise
  • Status

Company

  • Careers
  • Blog
  • Community

Policies

  • Subprocessors
  • Terms of Service

I have a GitHub sync error

In case of errors, make sure that:‌

  • Your repository has a README.md file at its root (or at the root folder specified in your .gitbook.yaml). This file is required and is used as the homepage for your documentation. For more details, refer to our .

  • If you have YAML frontmatters in your Markdown files, make sure they are valid using a .​

​GitBook is not using my docs folder

By default, GitBook uses the root of the repository as a starting point. A specific directory can be specified to scope the markdown files. Take a look at our documentation on for more details.‌

GitBook is creating new markdown files

When synchronizing and editing from GitBook with an existing Git repository, GitBook may create new markdown files instead of using the existing ones.‌ This is done to ensure GitBook doesn't overrite files that existed in your repository before.

​My repository is not listed

For GitHub repositories

Make sure that you have installed the GitBook GitHub app to the correct locations (when installing the app, you can choose to install it to your personal GitHub, or to any organization you have permissions for) and that you have given the app the correct repository permissions.

For GitLab repositories

Make sure that your access token has been configured with the following access:

  • api

  • read_repository

  • write_repository

​Nothing happens on GitBook after adding a new file to my repository

This section specifically addresses problems when a SUMMARY.md file already exists

If your repository does not include a SUMMARY.md file, GitBook will automatically create one upon the first sync. This means that if you edited your content from GitBook at least once after setting up Git sync, GitBook should have created this file automatically.‌

This could either be because you created the file manually, or because you made an edit on GitBook and the GitBook to Git export phase of the sync created it for you.

GitHub preview is not showing

If your GitHub preview is not showing, it might be because your GitSync integration was configured before January 2022. Versions of GitSync configured before this date do not include GitHub Preview.

You should have received a notification requesting you to accept an updated permission request to enable read-only access to PRs.

In case you did not receive the notification, to troubleshoot you need to update to the new version:

  1. Uninstall the GitSync integration from your organization.

  2. Reinstall the new version with the updated permissions.

Please note that uninstalling the GitSync integration will require reconfiguring the integration again on any spaces it was previously connected to.

Potential duplicated accounts when signing in

This error usually occurs when the GitHub account that you use to set up the sync is already associated with a different GitBook user account.

A good way to identify which GitBook account the GitHub account is already linked to is:

  1. Log out from your current GitBook user session (i.e. name@email.com)

  2. Log out from any GitHub user sessions.

  3. Select the "Sign in with GitHub" option.

  4. Enter your GitHub credentials.

    1. Unlink the account from the "Third-party Login > GitHub" section in the Personal setting

    2. Delete the account altogether if you do not need it.

  5. Log out from the session.

  6. Log back in using your name@email.com GitBook account.

  7. Try to set up Git Sync again.

If after updating your repository by adding or modifying a markdown file, you do not see the update reflected on GitBook and the sidebar doesn’t indicate an error during the sync, your modified file(s) is probably not listed in .‌

The content of this file mirrors your on GitBook and is used during the Git to GitBook import phase of the sync to recreate your table of contents and re-conciliate upcoming updates from the repository with your existing content on GitBook.‌

If after ensuring that all your files are included in the SUMMARY.md file there’s still nothing happening on GitBook, don’t hesitate to for assistance.

Go to .

Once logged in, go to and either:

content configuration
linter
content configuration
contact support
the Log in page
the account settings
table of contents
your SUMMARY.md file