Skip to content

Self-host Gogs

updated Aug 2026prices checked · Aug 2026Install verified on Ubuntu 26.04 · Aug 2026 · how we test

A self-hosted Git service that ships as one small Go binary — the original project Gitea and later Forgejo were forked from, still maintained and still the leanest of the three. Repositories, issues, pull requests, wiki and webhooks are all there; a built-in CI runner is not.

Key facts

CategoryCode hosting
LicenseMIT
StackGo
Min RAM512 MB
Dockeryes
Difficulty
Our recommendation

Pick Gogs when you want the smallest forge that still has the parts you actually use — repositories, issues, pull requests, a wiki and webhooks — and you deliberately do not want a CI runner living in the same process. It is the older, simpler project Gitea was forked from, and it stayed on that original goal while Gitea and Forgejo went further with built-in Actions runners, package registries and a much faster release cadence. Upstream's documented baseline is 2 CPU cores and 512 MB of RAM, which makes it the cheapest real forge on this hub. Take Gitea or Forgejo instead the moment you want the runner in the box; take Soft Serve if you did not want a web forge at all.

What you need

  • Any VPS with at least 512 MB of RAM
  • A domain you control — most self-hosted setups need HTTPS in front of them
  • Under an hour if you've used Docker before

Install with Docker Compose

Save this as compose.yml and run docker compose up -d:

# Gogs — upstream's documented Docker layout (SSH on 10022, web on 10880)
services:
  gogs:
    image: gogs/gogs:0.14
    ports: ["10022:22", "10880:3000"]
    volumes: ["./gogs:/data"]
# docker compose up -d  →  http://SERVER_IP:10880 for the install wizard
# the first account you register becomes the admin

What you take on

Gogs is the least demanding thing here to run, and what you take on is mostly what it deliberately leaves out:

non-negotiableThere is no CI runner inside Gogs. You get repository webhooks, Git hooks and deploy keys, so it can trigger Jenkins, Woodpecker or Drone — but that runner is a second service to install, secure and upgrade, and it is the piece Gitea and Forgejo hand you for free.
non-negotiableDo not track the latest container tag. Upstream is mid-transition to a new image that is scheduled to take over latest at a future release and demote the current one, so an unattended pull can swap the image out from under a running install. The snippet above pins a minor tag on purpose — keep it pinned and read the release notes before you move it.
non-negotiableThe install wizard is unauthenticated until you finish it, and the first account you register becomes the administrator. Complete the wizard and claim that account before the port is reachable from anywhere you do not control, and put a reverse proxy with TLS in front — the Compose layout above publishes plain HTTP.

An alternative to

Head-to-head

More in Code hosting

Common questions

Gogs or Gitea?

Gitea is the fork, and it moved further: built-in Actions CI, package registries, a much faster release cadence and a far larger contributor base. Gogs stayed close to its original goal — a painless Git service in one binary — and is still actively maintained, so pick it when you want the smallest possible forge and none of the CI machinery.

Does Gogs have built-in CI?

No. Gogs has repository webhooks (including Slack, Discord and Dingtalk), Git hooks and deploy keys, so it can trigger Jenkins, Woodpecker or anything else that listens — but there is no runner inside Gogs itself. Gitea and Forgejo are where you go if you want the runner in the same box.

How much hardware does Gogs need?

Very little — upstream names a Raspberry Pi as enough to get started and 2 CPU cores with 512 MB of RAM as the baseline for a team. Memory footprint stays flat as the team grows; upstream's advice is to add CPU cores rather than RAM.

Which databases does Gogs support?

SQLite3, PostgreSQL, MySQL and MariaDB, plus anything that speaks one of those protocols. SQLite keeps the whole install to a single container with one volume, which is why the snippet above needs no database service at all.

We use analytics cookies (Google Analytics, PostHog) to see which guides are useful. No ad networks, no cross-site tracking. See our privacy policy.