Developer tools

Forgejo VPS requirements: RAM, CPU, disk, and what actually breaks it

By VPSfit · Sources checked · Forgejo website · source code · GPL-3.0-or-later

Forgejo is a self-hosted Git forge, a community fork of Gitea run under the Codeberg e.V. umbrella, with repositories, pull requests, issues, a package registry and GitHub-style CI (Forgejo Actions). It is written in Go and ships as one binary or one container, and it is light: published tests put the server at roughly 150–320 MiB. The project publishes no hardware minimum. A private forge for one person or a small team fits a 1 GB plan. What decides the size of the server is rarely Forgejo itself. It's CI jobs if you run a runner on the same box, and, on a public instance, scrapers that crawl every file at every commit.

Sizing guide

Our recommendations, derived from the sourced figures below. Not measurements.

ScenarioRAMvCPUWhy
Private forge for one person or a small team, SQLite, no CI on the box1 GB1Published tests put Forgejo at about 150–320 MiB, so 1 GB leaves room for the OS, a reverse proxy and big clones. Keep the instance private or behind a VPN so crawlers never reach it. We haven't measured it on a 1 GB VPS yet.
Team instance with PostgreSQL, or any instance open to the internet2 GB1–2Postgres added about 73 MiB at idle in one test, but the real reason is headroom: a public 2 GB server was swapping with Forgejo at 1.1 GB under bot traffic. Pair it with a bot filter (below), not just more RAM.
Forgejo plus an Actions runner on the same VPS4 GB or more2+Our estimate, not a measurement. The idle runner is about 8 MiB; the jobs are whatever your builds need, plus the job containers. Size for your heaviest build, or put the runner on a separate machine, which the security docs also favor.
Large repositories with code search turned on2–4 GB2The indexer is off by default and uses about six times the repository size in disk. Indexing and diff rendering of big files are the CPU and RAM spikes; we found no published RAM figure for indexing.

Official requirements

ItemWhat the project saysSource
Minimum resourcesNone published. The installation, database and recommended-settings pages give no RAM, CPU or disk figure. The recommended-settings page suggests settings for small instances instead (see below)Forgejo docs: Recommended Settings and Tips
checked Oct 29, 2026
Install methodsContainer image codeberg.org/forgejo/forgejo (a 17 tag that follows the newest 17.x, and a -rootless variant), a single binary run by a git user under systemd, or distribution packages. The binary install needs git and git-lfs on the host. The example compose file publishes the web UI on 3000 and container SSH on 222Forgejo docs: Installation with Docker; Installation from binary
checked Oct 29, 2026
DatabasesSQLite (built into the official binary), PostgreSQL 14 or newer, MariaDB 10.6 or newer, or MySQL 8.4 or newer (InnoDB). The docs recommend SQLite for low to moderate activity and PostgreSQL or MySQL for high activity, and warn that switching databases later is not trivialForgejo docs: Database Preparation; Recommended Settings
checked Oct 29, 2026
Cache on small instancesThe default cache keeps up to 50,000 items for 16 hours. For an instance without much activity the docs recommend ADAPTER = twoqueue with a 100-item size limit, and Redis, Valkey or Memcache for busy onesForgejo docs: Recommended Settings, [cache].ADAPTER
checked Oct 29, 2026
Code searchOff by default (REPO_INDEXER_ENABLED = false), so search works per repository with git grep. Turning the indexer on "uses a lot of disk space, about 6 times more than the repository size"Forgejo docs: Configuration Cheat Sheet, indexer
checked Oct 29, 2026
Source archivesDownload-as-zip/tar.gz archives are generated on request and kept on disk. A built-in cron job deletes archives older than 24 hours at midnight. DISABLE_DOWNLOAD_SOURCE_ARCHIVES turns the downloads off, and the docs suggest a robots.txt rule (Disallow: /*/*/archive/) so crawlers don't fill the diskForgejo docs: Search Engines Indexation; Config Cheat Sheet
checked Oct 29, 2026
ActionsEnabled by default since v1.21, but Forgejo doesn't run jobs itself. A separately installed Forgejo Runner does, and the docs stress that a runner "performs remote code execution" and needs its own security planningForgejo docs: Forgejo Actions administrator guide; Securing Forgejo Actions Deployments
checked Oct 29, 2026
Release linesA stable release every quarter. 15.0 is the long-term support line until 15 July 2027 (15.0.11, 26 Oct 2026). 17.0 is current until 28 January 2027 (17.0.1, 26 Oct 2026). 16.0 reaches end of life on 29 October 2026. Upgrading across a major version (16 to 17) needs a manual checkForgejo docs: Release schedule
checked Oct 29, 2026
17.0.0 warningThe 17.0.0 release page still says "We currently advise against upgrading to Forgejo 17.0.0" because of an issue that "prevents pushing, merging, or other code operations in some cases". The 17.0.1 notes list security and bug fixes; we couldn't confirm from them that this issue is resolvedCodeberg: Forgejo v17.0.0 release
checked Oct 29, 2026

What people report in practice

Individual reports, not controlled tests. Versions, hardware and settings differ, so treat these as data points, not guarantees.

  • Forgejo 15.0.10 with PostgreSQL 17 and an idle runner averaged 285.7 MiB (peak 300.1 MiB) and under 1% of one CPU core: about 204 MiB for Forgejo, 73 MiB for Postgres and 8 MiB for the runner. Forgejo 17.0.0 idled at 315.3 MiB on the same host. Images were 188 MB (Forgejo), 297 MB (Postgres) and 46 MB (runner) unpacked, and the stack answered its health check 5.4 seconds after start

    Comparison test against GitLab CE on an 8 vCPU host, 19 Oct 2026. Idle averages from docker stats after a pipeline, a registry push, a migration and a backup

    Blog DEV Community (deploylark): GitLab CE vs Forgejo, self-hosted Git on Docker, measured · checked Oct 29, 2026

  • Peak RAM during YunoHost's package test was 231 MB for Forgejo, against 372 MB for Gitea, with 146 MB still in use after the test. The thread started because the Forgejo package asked for 2 GB and the Gitea package for 100 MB

    YunoHost forum, Jan 2025, quoting the packaging CI job. A short automated install test, not a production instance

    Forum YunoHost forum: RAM usage for Gitea and Forgejo · checked Oct 29, 2026

  • On a 2 GB server, Forgejo reached 1.1 GB resident (55% of RAM) and the machine was swapping, with requests taking up to 490 seconds, after "bots were hitting very hard on /issues?assignee and /pulls?assignee the whole night". In the same thread, a user who saw 8.4 GiB in docker stats got a diagnosis report showing 77.8 MB of Forgejo heap, and a maintainer said there's no leak; the rest was likely page cache

    Codeberg issue thread, Mar to May 2026, Forgejo 14.0.3 and a PostgreSQL install with the twoqueue cache

    Codeberg Codeberg forgejo #11847: Instance Memory Leak · checked Oct 29, 2026

  • Bots found the auto-generated source archive links and downloaded them at up to 100 Mb/s. "Once hundreds of gigabytes of archives consumed all disk space, memory usage also spiked", and most services on the server went offline. robots.txt didn't stop them; a proof-of-work and challenge proxy (go-away) did

    Personal blog of a Forgejo admin, May 2025

    Blog Jade Ellis: Actually stopping AI scrapers from taking down my server · checked Oct 29, 2026

  • A small personal Forgejo on a VPS, used for projects like Advent of Code solutions, received about 600,000 crawler requests a day (about 10 per second): every file at every commit, blame views, archives and every issue and pull request filter combination. Anubis cut most of it, and a cookie check in Caddy that lets git, git-lfs and runner traffic through did the rest

    Personal blog, Dec 2025

    Blog Honeypot.net: How I protect my Forgejo from AI crawlers · checked Oct 29, 2026

  • Forgejo 7.0.4 and 7.0.5 sometimes climbed to 14–17 GB of RAM and all 8 cores until the admin killed it. A maintainer traced the heap profile to the syntax highlighter (Chroma) rendering a diff; another commenter pointed to scrapers requesting expensive diffs. The reporter found 8.0 fixed it for them

    Codeberg issue, July to Aug 2024, on an 8-core VPS. An old version, but it shows what one expensive page can do without a memory limit

    Codeberg Codeberg forgejo #4428: Randomly Forgejo begins using a lot of RAM and CPU · checked Oct 29, 2026

Our measurements: coming soon

We haven't measured Forgejo yet, so there are no VPSfit lab numbers on this page. When we do, they'll show the app version, the plan it ran on, the date, and the raw data. Here's what we'll record:

  • Idle and 24-hour RAM of Forgejo 15.0 LTS with SQLite on a 1 GB plan, private, with ten repositories
  • RAM and response times on a public 1 GB and 2 GB plan with and without a challenge proxy in front
  • Peak RAM and CPU while cloning, diffing and blaming a large repository (Linux kernel mirror)
  • Disk use of the code indexer against repository size

How we measure →

What drives Forgejo's RAM use

A small Go binary, then whatever the requests cost

An idle Forgejo sits around 200 MiB, and a diagnosis report from a running instance showed under 80 MB of Go heap (#11847). Memory goes up with work: rendering large diffs with syntax highlighting, blame views, search and big clones. One expensive diff took a 7.0.x instance to 14–17 GB (#4428). Normal use by a few people never gets near that.

Crawlers multiply the expensive pages

A forge exposes every file at every commit, every blame and every filter combination as its own URL. Scrapers that walk them all turn a personal server with a handful of real visitors into one serving about 600,000 requests a day (Honeypot.net). That is what pushed one 2 GB server into swap (#11847). A private instance doesn't have this problem.

Disk: repositories, LFS, packages, archives and the indexer

Everything users push lands on the server's disk: repositories, LFS objects, the package registry and Actions logs and artifacts. Two settings can grow it quickly. The code indexer uses about six times the repository size (cheat sheet), and source archives are generated on request and kept for up to a day, which is how crawlers filled one server's disk with hundreds of gigabytes (Jade Ellis). The container image itself is about 188 MB unpacked (deploylark).

CI is a separate workload

Forgejo only queues Actions jobs. The runner runs them, usually in containers, and a build can need far more RAM and CPU than the forge. The runner idled at about 8 MiB in one test (deploylark); the jobs are what you size for.

Gotchas on a VPS

  • Keep public instances behind a bot filter. robots.txt helps with search engines, but admins report scrapers ignoring it (Jade Ellis). What worked for them was a challenge proxy such as Anubis or go-away in front of Forgejo, letting git, git-lfs and runner traffic through (Honeypot.net). If the forge is just for you, keep it private: set REQUIRE_SIGNIN_VIEW or reach it over a VPN or tunnel such as Pangolin, Tailscale or WireGuard.
  • Turn off source archives you don't need. Each download-as-zip creates an archive on disk that stays until the nightly cleanup (cheat sheet). Set DISABLE_DOWNLOAD_SOURCE_ARCHIVES = true, or at least add Disallow: /*/*/archive/ to robots.txt as the docs suggest (docs).
  • Close registration. Registration is open by default (DISABLE_REGISTRATION = false). With Actions enabled, an unknown account that can create a repository can try to run workflows on your runner, which the security guide treats as remote code execution (docs). Set DISABLE_REGISTRATION = true and create accounts as the admin.
  • Ports 3000 and 222 are public by default. The example compose file publishes 3000:3000 and 222:22 on every interface (docs), and Docker's port rules bypass UFW. Bind the web port to 127.0.0.1 behind a reverse proxy with HTTPS, and leave the VPS's own SSH on port 22 so Git over SSH and admin logins don't collide.
  • Pick the release line on purpose. There's no latest tag, and a major upgrade needs a manual check. 15.0 LTS is supported until July 2027, and 16.0 reaches end of life on 29 October 2026 (release schedule). The 17.0.0 release page still warns against upgrading because of a push and merge issue (release). On a server you don't want to babysit, pin the 15 tag.
  • Use the small-instance cache setting. The docs suggest [cache] ADAPTER = twoqueue with a 100-item limit for quiet instances, because the default can hold 50,000 items for 16 hours (docs). Set a container memory limit too, so a runaway request restarts Forgejo instead of freezing the VPS.
  • Check memory with docker stats or the admin dashboard. Some dashboards count page cache as container memory. In one report a tool showed 8.4 GiB while Forgejo's own diagnosis found 77.8 MB of heap (#11847). Use docker stats --no-stream or Site Administration's system status before resizing the server.

Cheapest plans that fit

Forgejo, private, SQLite, no CI on the box: 1 GB RAM and 1+ vCPU

Threshold: No official figure. Tests reported about 150–320 MiB for Forgejo, and 1 GB leaves room for the OS, a proxy and large clones (source). Only plans with at least 1 vCPU are listed.

Provider & planRAMvCPUDisk Price / monthTermsSource
Contabo Cloud VPS 4 8 GB 4 shared 100 GB SSD €4.40
excl. VAT · ≈ $4.93
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Vultr Cloud Compute Regular 1 GB 1 GB 1 shared, previous-gen Intel 25 GB SSD $5.00
before tax
Monthly price, hourly billing vultr.com
checked Oct 28, 2026
DigitalOcean Basic 1 GiB 1 GB 1 shared 25 GB SSD $6.00
before tax
Monthly cap, per-second billing digitalocean.com
checked Oct 28, 2026
Contabo Cloud VPS 6 12 GB 6 shared 200 GB SSD (or 100 GB NVMe) €6.00
excl. VAT · ≈ $6.73
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026

Forgejo with PostgreSQL or open to the internet: 2 GB RAM and 1+ vCPU

Threshold: No official figure. A public 2 GB server swapped with Forgejo at 1.1 GB under bot traffic, so 2 GB is a floor that still needs a bot filter (source). Only plans with at least 1 vCPU are listed.

Provider & planRAMvCPUDisk Price / monthTermsSource
Contabo Cloud VPS 4 8 GB 4 shared 100 GB SSD €4.40
excl. VAT · ≈ $4.93
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Contabo Cloud VPS 6 12 GB 6 shared 200 GB SSD (or 100 GB NVMe) €6.00
excl. VAT · ≈ $6.73
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Vultr Cloud Compute Regular 2 GB 2 GB 1 shared, previous-gen Intel 55 GB SSD $10.00
before tax
Monthly price, hourly billing vultr.com
checked Oct 28, 2026
Hostinger KVM 1 4 GB 1 AMD EPYC 50 GB NVMe $11.99
intro $6.49
before tax
Prepaid intro rate; renews at $11.99/mo hostinger.com
checked Oct 28, 2026

Forgejo plus an Actions runner on the same VPS: 4 GB RAM and 2+ vCPU

Threshold: Our estimate, not a measurement: Forgejo's few hundred MiB plus room for typical container builds. Size up for heavy builds (source). Only plans with at least 2 vCPUs are listed.

Provider & planRAMvCPUDisk Price / monthTermsSource
Contabo Cloud VPS 4 8 GB 4 shared 100 GB SSD €4.40
excl. VAT · ≈ $4.93
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Contabo Cloud VPS 6 12 GB 6 shared 200 GB SSD (or 100 GB NVMe) €6.00
excl. VAT · ≈ $6.73
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Contabo Cloud VPS 8 24 GB 8 shared 300 GB SSD (or 150 GB NVMe) €11.20
excl. VAT · ≈ $12.56
24-month term (effective monthly rate) contabo.com
checked Oct 28, 2026
Hostinger KVM 2 8 GB 2 AMD EPYC 100 GB NVMe $14.99
intro $8.79
before tax
Prepaid intro rate; renews at $14.99/mo hostinger.com
checked Oct 28, 2026

Prices checked Oct 28, 2026 on each provider's official pricing page. EUR prices converted at the ECB rate of Oct 27, 2026 (1 € = $1.115) only for ranking. See all plans on the cheapest 4 GB VPS page.