# Connecting GitLab

Connecting GitLab gives the Seal Platform read access to the GitLab projects you choose, so they can run in [source code mode](/new-documentation/new-docs/package-discovery-mode/source-code.md). The GitLab integration covers discovery; remediation runs through the Seal CLI in your CI/CD pipeline (or one of the other deployment methods).

## Before you start

* You have the **Admin** or **Sealer** [role](/new-documentation/new-docs/users-and-sso/user-roles.md) in Seal.
* You have the URL of your GitLab instance (for example, `https://gitlab.com/your-organization/` for GitLab.com, or your self-hosted URL).
* You have a GitLab **personal access token** with the `api` scope, generated by a user with **Developer**, **Maintainer**, or **Owner** role on the projects you want to import.

## Steps

1. Open the **Projects** page in the Seal UI.
2. Click **Import projects** and select **GitLab** from the dropdown.
3. **If GitLab is not yet connected**, the modal opens at the **LOGIN** step. Fill in:
   * **GitLab URL** (the URL of your GitLab instance).
   * **Personal Access Token** (with the `api` scope).
4. **If GitLab is already connected**, the modal opens directly at the **IMPORT** step.
5. In the IMPORT step, select the GitLab projects you want to import as Seal Projects, then confirm.

## Verify

Each imported project becomes a Seal Project in source code mode. The first scan starts in the background; results appear on the Protection page's Vulnerable packages tab as the scan completes.

## Related

* [Source code mode](/new-documentation/new-docs/package-discovery-mode/source-code.md): what Seal sees once GitLab is connected.
* [Managing source control connections](/new-documentation/new-docs/connecting-source-control/managing-connections.md): viewing or disconnecting the GitLab installation.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sealsecurity.io/new-documentation/new-docs/connecting-source-control/gitlab.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
