Skip to content
Hosting

Go hosting

Push a Go repo and Ownkube builds the binary and runs it on a public HTTPS hostname. Go services are small and start fast, which suits metered pricing: an idle Go API holds little memory and bills almost nothing on CPU. Managed Postgres, logs, metrics and rollbacks come built in.

Go hosting at a glance

  • Automatic Go builds, or your own multi-stage Dockerfile.
  • Listen on 0.0.0.0 and read PORT, commonly 8080.
  • Small static binaries start quickly, including after an idle app wakes from sleep.
  • Link Postgres and read DATABASE_URL with database/sql or pgx.

How to host a Go app on Ownkube

  1. 1

    Connect the repo

    Sign in, connect GitHub or GitLab, and pick the repo. Ownkube detects Go and builds the binary.

  2. 2

    Set the port

    Read the PORT variable at startup, bind 0.0.0.0, and set the same port on the deployment.

  3. 3

    Deploy

    The app goes live on its *.ownkube.app hostname with HTTPS. Turn on autoscaling on CPU or memory when traffic grows.

The step by step version, with code: How to deploy a Go app on Ownkube.

What Go hosting costs

Metered usage bills about $18 per vCPU and $4.50 per GiB a month, per minute. Databases run on flat boxes plus $0.25 per GB of storage. Everything draws one prepaid wallet, and unused credit never expires.

Workload Setup Per month
Small Go API 0.05 vCPU average, 0.25 GiB held about $2
Go API with Postgres Same app + DB 0.5 box ($4) + 5 GB storage ($1.25) about $7.30
Steady Go service, flat price Spark 1 box (0.25 vCPU, 0.5 GiB) $5

Estimates for one month of continuous running. See pricing for every box and rate.

How Ownkube compares for Go hosting

The smallest app plus a small managed Postgres on each platform, from each provider's public pricing page.

Platform App Managed Postgres Billing
Ownkube Metered at about $18 per vCPU and $4.50 per GiB a month, or a $5 Spark 1 box From $4 a month plus $0.25 per GB Prepaid wallet, unused credit never expires
Railway Metered at about $20 per vCPU and $10 per GB a month Runs as a metered service plus $0.15 per GB volume Postpaid, $5 Hobby plan includes $5 of usage
Render From $7 a month (0.5 CPU, 512 MB) From $6 a month plus $0.30 per GB Postpaid, workspace plan from $0
Fly.io From $2.19 a month (shared-cpu-1x, 256 MB) Managed from $38 a month plus $0.28 per GB Postpaid, pay as you go
Heroku Eco $5 or Basic $7 a month Essential-0 from $5 a month Postpaid, per dyno

List prices checked 2026-10-13. For a full-stack estimate, try the cost calculator.

Go hosting questions

Something else? Email support@ownkube.io.

What is the cheapest way to host a Go app?

Metered hosting suits Go well, because a Go service holds little memory and uses little CPU at rest. A small Go API runs for about $2 a month of usage on Ownkube, drawn from a prepaid wallet.

Do I need a Dockerfile for Go?

No. Ownkube detects Go and builds the binary automatically. Add a multi-stage Dockerfile if you want control over the build and the base image.

Can I host a Go app with a database?

Yes. Link a managed Postgres database and Ownkube injects DATABASE_URL. It works with database/sql, pgx, or any driver that reads a connection string.

Can a Go app autoscale?

Yes. Turn on autoscaling in the deployment settings and Ownkube adds replicas under load and removes them when load drops, based on live CPU and memory against targets you set.

Host your Go app

Push the repo and get a live HTTPS URL. No cloud account to set up.

Deploy my first app