# AI code review for Gitea and Forgejo pull requests

Connect your Gitea or Forgejo server with an access token. MergeHarbor reviews each pull request with the context of the whole repository, posts a review with inline comments, and reports a commit status.

[Start free trial](https://app.mergeharbor.com/signup) [Gitea and Forgejo setup](https://mergeharbor.com/docs/gitea)

14 days of the Team plan, no card needed.

.mergeharbor.yml

```
review:
  trigger: pushes
  categories: [correctness, security, concurrency, error_handling]
  min_severity: minor
  max_comments: 25
```

## What MergeHarbor does on Gitea and Forgejo

Pull request reviews

Findings are posted as a pull request review with inline comments on the changed lines, and a summary of the change.

A commit status

Each review reports a commit status, and the merge gate reports MergeHarbor / merge gate. Require either in your branch protection.

Reactions feed learning

Thumbs up and thumbs down on MergeHarbor's comments tell it what your team values, alongside fixes and dismissals.

Commands in comments

Comment @mergeharbor review, @mergeharbor remember or another command, or start the comment with mergeharbor review without the @.

## Connect Gitea or Forgejo

1.  ### Create a token

    Create an access token for a service account with the write:repository, write:issue and read:user scopes.

2.  ### Connect

    In the console, choose Gitea / Forgejo, enter your instance URL and paste the token.

3.  ### Choose repositories

    Pick the repositories to review. MergeHarbor registers the webhooks automatically.

[Read the full gitea and Forgejo setup](https://mergeharbor.com/docs/gitea)

## Other code hosts

-   [GitLab and GitLab Self-Managed](https://mergeharbor.com/ai-code-review/gitlab)
-   [Bitbucket Cloud and Bitbucket Data Center](https://mergeharbor.com/ai-code-review/bitbucket)
-   [Azure DevOps Services and Server](https://mergeharbor.com/ai-code-review/azure-devops)
-   [GitHub and GitHub Enterprise Server](https://mergeharbor.com/ai-code-review/github)
-   [Perforce Helix Core and Helix Swarm](https://mergeharbor.com/ai-code-review/perforce)
-   [All integrations](https://mergeharbor.com/integrations)

Running your code host on a private network? See [self-hosted AI code review](https://mergeharbor.com/ai-code-review/self-hosted).

## Further reading

[Guide · 9 min read How AI code review works, step by step What happens between opening a pull request and the first AI review comment, from the webhook and the code index to verification, posting and learning. Read the guide](https://mergeharbor.com/guides/how-ai-code-review-works) [Guide · 8 min read How to reduce false positives in AI code review Why AI reviewers post wrong or unwanted comments, and the settings, rules and feedback loops that cut the noise without hiding real bugs. Read the guide](https://mergeharbor.com/guides/reduce-false-positives)

## Frequently asked questions

Does it work with Forgejo and Codeberg?

Yes. Choose Gitea / Forgejo in the console and enter your instance URL. Public repositories on gitea.com and codeberg.org can be reviewed for free under the open-source program once a billing admin selects them.

What does the access token need?

The write:repository, write:issue and read:user scopes, on a service account rather than a person's account.

Is Gitea support generally available?

On Gitea and Forgejo, inline review comments, the status check, auto-approve, description updates, commands and reactions as feedback are supported.

Our Gitea server is on a private network. Can MergeHarbor reach it?

Your server must be reachable from MergeHarbor, and your Gitea must be able to reach MergeHarbor's webhook URL. For a server that is not reachable from the internet, run MergeHarbor self-hosted inside your network.

How do we try it?

Sign up and connect a code host. Every new organization gets the Team plan free for 14 days with no card, including the Deep review tier and the merge gate. If no one subscribes, reviews pause when the trial ends and nothing is deleted.

Have another question? [Ask our support team](https://mergeharbor.com/contact?topic=support)

## Add AI review to your Gitea or Forgejo server

Paste an access token and choose repositories. Reviews start on the next pull request.

[Start free trial](https://app.mergeharbor.com/signup) [Book a demo](https://mergeharbor.com/contact?topic=sales&source=demo)
