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

# Quickstart

> Install Gitar and see it review a PR in under 5 minutes.

export const ThemeImage = ({src, alt}) => {
  let lightSrc, darkSrc;
  if (src.includes("-light.")) {
    lightSrc = src;
    darkSrc = src.replace("-light.", "-dark.");
  } else if (src.includes("-dark.")) {
    darkSrc = src;
    lightSrc = src.replace("-dark.", "-light.");
  } else {
    lightSrc = src;
    darkSrc = src;
  }
  return <span>
      <img className="block dark:hidden rounded-lg border" src={lightSrc} alt={alt} />
      <img className="hidden dark:block rounded-lg border" src={darkSrc} alt={alt} />
    </span>;
};

<Note>
  **5-minute setup** — free 14-day trial, no credit card required.
</Note>

By the end of this guide you'll have Gitar installed on a repository and see it automatically review a pull request.

## Prerequisites

* A **GitHub** or **GitLab** account with admin access to at least one organization or group
* An **open pull request**, or a repository where you can create one

## Step 1: Sign in to Gitar

Go to [app.gitar.ai](https://app.gitar.ai) and sign in with your GitHub or GitLab account. You'll see the **Connect Your Code** screen.

<ThemeImage src="/assets/images/connect-code-with-invite-light.png" alt="Connect Your Code screen" />

## Step 2: Connect your repository

<Tabs>
  <Tab title="GitHub">
    Click **Install** to add the Gitar GitHub App to your organization. You can grant access to **all repositories** or **select specific ones**.

    <ThemeImage src="/assets/images/connect-code-connected-light.png" alt="Repositories connected in Gitar onboarding" />

    <Tip>
      You can change repository access at any time from your GitHub organization settings under **Installed GitHub Apps**.
    </Tip>
  </Tab>

  <Tab title="GitLab">
    GitLab connection uses a service account with a Personal Access Token (PAT) for repository access.

    1. Create a **service account** in your GitLab group with Developer role or higher
    2. Generate a **Personal Access Token** with `api`, `read_api`, `read_user`, `read_repository`, and `write_repository` scopes
    3. Enter the token in the Gitar dashboard to connect your projects

    <ThemeImage src="/assets/images/connect-code-connected-light.png" alt="Repositories connected in Gitar onboarding" />

    See the [full GitLab connection guide](/connecting-code/gitlab) for detailed steps, including self-managed GitLab setup.
  </Tab>
</Tabs>

## Step 3: Connect integrations (optional)

Gitar can pull context from issue trackers and observability tools to enrich reviews and rules. You can connect **Jira**, **Linear**, and others now, or skip and add them later from settings.

<ThemeImage src="/assets/images/connect-code-integrations-light.png" alt="Integrations step in Gitar onboarding" />

## Step 4: See Gitar in action

Once connected, Gitar runs an initial scan of your repositories. You have two ways to see it work:

1. **Open a new PR** — Create a pull request with some changes. Gitar starts working automatically on any PR activity in connected repositories.
2. **Try Gitar on existing PRs** — Look for the "Try Gitar on Open PRs" card in the dashboard to trigger Gitar on your existing pull requests.

<ThemeImage src="/assets/images/try-gitar-prs-light.png" alt="Try Gitar on your open PRs card in dashboard" />

## Step 5: Review Gitar's feedback

Within a few minutes, Gitar posts a **dashboard comment** on your PR with an overview of its analysis.

<ThemeImage src="/assets/images/dashboard-comment-light.png" alt="Gitar dashboard comment on a pull request" />

Here's what happens next:

* **CI fails** — Gitar analyzes the failure and posts a root cause. If auto-apply is enabled (or you ask for a fix), Gitar pushes a fix commit.
* **Code review** — Gitar posts inline review comments on the lines with issues, with a consolidated summary in the dashboard comment
* **Comment instructions** — Reply to Gitar's comment with natural language to ask for changes

<Note>
  Gitar **never force-pushes** to your branch. All fixes are added as new commits so your history stays intact.
</Note>

## Next steps

<CardGroup cols={2}>
  <Card title="Gitar Dashboard" icon="book-open" href="/gitar-dashboard">
    Learn about dashboard comments, display modes, and auto-apply
  </Card>

  <Card title="Repository Rules" icon="scroll" href="/features/rules">
    Create automated workflows using natural language
  </Card>

  <Card title="CI Failure Analysis" icon="circle-check" href="/features/ci-failure-analysis">
    Deep dive into how Gitar analyzes and fixes CI failures
  </Card>

  <Card title="Connect Your Code" icon="plug" href="/connecting-code/github">
    Connect GitHub, GitLab, and custom CI providers
  </Card>
</CardGroup>
