> ## Documentation Index
> Fetch the complete documentation index at: https://docs.wolfia.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GitLab Integration for Knowledge Sync

> Connect Wolfia to GitLab and sync documentation, policies, and other files from your projects into your knowledge base.

## Overview

If your policies, runbooks, and product documentation live in GitLab, you can make them answerable in Wolfia directly from the source. You pick the projects, branches, and files to include, and Wolfia keeps its knowledge base in step with the project as files change.

<img src="https://mintcdn.com/wolfia/yPbcoGNiai_1OdRy/images/integrations/gitlab/gitlab-knowledge-hub-synced-files.png?fit=max&auto=format&n=yPbcoGNiai_1OdRy&q=85&s=5c808eb1a27c94437fd567eec4af5913" alt="GitLab synced files in the Knowledge Hub" width="3600" height="1972" data-path="images/integrations/gitlab/gitlab-knowledge-hub-synced-files.png" />

## What we sync

* **Documentation files** - Markdown (`.md`, `.mdx`), plain text, HTML, and JSON
* **Office documents** - Word (`.docx`, `.doc`), Excel (`.xlsx`, `.xlsm`, `.xls`), PowerPoint (`.pptx`), and CSV
* **PDFs** - Policy documents, reports, and attestations
* **Images** - PNG, JPG, and WebP diagrams such as architecture overviews
* **Email files** - `.eml` messages saved into the project

The connection is read-only. Wolfia never writes to your projects.

## Prerequisites

* A GitLab.com account with membership in the projects you want to sync
* **Admin role in Wolfia** to connect the integration

## Setup instructions

<Steps>
  <Step title="Connect GitLab">
    Navigate to **Knowledge Hub** in the left sidebar, find the **GitLab** integration, and click **Connect**. Sign in to GitLab and authorize Wolfia when prompted. Wolfia requests read-only access to your projects.
  </Step>

  <Step title="Select projects and branches">
    Click **Manage projects**, pick the projects to sync, and choose the branch to read from for each one.

    <img src="https://mintcdn.com/wolfia/yPbcoGNiai_1OdRy/images/integrations/gitlab/gitlab-manage-projects.png?fit=max&auto=format&n=yPbcoGNiai_1OdRy&q=85&s=9ca7139dfcbf7fb87c9968f06db07d78" alt="Manage GitLab projects dialog" width="3600" height="1972" data-path="images/integrations/gitlab/gitlab-manage-projects.png" />
  </Step>

  <Step title="Pick the files to include">
    Browse the project file tree and select the folders and files to bring into your knowledge base. Only supported file types are selectable. Checking a folder includes every supported file under it, now and in the future.

    <img src="https://mintcdn.com/wolfia/yPbcoGNiai_1OdRy/images/integrations/gitlab/gitlab-file-picker.png?fit=max&auto=format&n=yPbcoGNiai_1OdRy&q=85&s=cdc82a999576d9ce1e8ce97c46115710" alt="Choosing files and folders to sync" width="3600" height="1972" data-path="images/integrations/gitlab/gitlab-file-picker.png" />
  </Step>

  <Step title="Sync">
    Click **Sync now** to run the first sync. Files appear in the Knowledge Hub with their project paths, grouped into folders such as Policies and Certifications & Audit Reports as they are classified.
  </Step>
</Steps>

## How syncing works

* **Automatic refresh** - Synced projects refresh once a day, so answers reflect your latest committed documentation.
* **Only changes are re-processed** - **Sync now** and the daily refresh compare each file against the version already synced. Unchanged files are skipped, so syncs stay fast even in large projects.
* **Deletions are honored** - When a synced file is removed from the project, its content is removed from your knowledge base on the next sync.
* **Facts are extracted automatically** - After a file syncs, Wolfia extracts the facts it contains so they can be used in questionnaire answers, chat, and RFP responses.

## Good practices

* Sync from your default branch so the knowledge base always reflects reviewed, merged content.
* Keep customer-facing documentation in dedicated folders (for example `docs/policies/`, `docs/security/`) and select those folders rather than the whole project.
* Use descriptive file names. The file path is shown in the Knowledge Hub and helps your team find sources quickly.

## FAQ

<AccordionGroup>
  <Accordion title="Which file types are supported?">
    Markdown, MDX, plain text, HTML, JSON, PDF, Word, Excel, PowerPoint, CSV, PNG, JPG, WebP, and EML files are supported. Unsupported file types do not appear in the file picker.
  </Accordion>

  <Accordion title="Does Wolfia read my source code?">
    Wolfia only syncs the files you explicitly select. If you select only documentation folders, source code is never read into the knowledge base.
  </Accordion>

  <Accordion title="What happens when I click Sync now?">
    Wolfia checks the selected files against the project and re-processes only the files that changed since the last sync. Files that are unchanged are skipped.
  </Accordion>

  <Accordion title="How do I disconnect?">
    Click **Disconnect** on the GitLab page in the Knowledge Hub. You can also revoke the authorization from your GitLab applications settings.
  </Accordion>
</AccordionGroup>

## Related pages

<CardGroup cols={2}>
  <Card title="GitHub integration" icon="github" href="/how-to/github-integration">
    Sync documentation from GitHub repositories the same way.
  </Card>

  <Card title="Knowledge base" icon="book" href="/how-to/knowledge-base">
    How Wolfia organizes and uses your synced knowledge.
  </Card>

  <Card title="Adding knowledge" icon="plus" href="/how-to/adding-knowledge">
    Other ways to bring content into Wolfia.
  </Card>

  <Card title="SharePoint integration" icon="microsoft" href="/how-to/sharepoint-integration">
    Sync documents from SharePoint sites.
  </Card>
</CardGroup>
