Skip to main content

Linkding with Docker Compose

Linkding is one container: sissbruecker/linkding on port 9090. It uses SQLite by default. Set LD_DB_ENGINE=postgres and the LD_DB_* variables to use PostgreSQL instead. LD_SUPERUSER_NAME and LD_SUPERUSER_PASSWORD create the admin account on the first start. Keep /etc/linkding/data on a volume.

Linkding is a small, fast bookmark manager with tags, full-text search, browser extensions and a REST API.

If you're new to Docker Compose, check out our guide on how to self-host a Docker Compose app. More stacks are in our Docker Compose library.

Self-host Linkding with Docker Compose (minimal)​

services:
linkding:
image: sissbruecker/linkding:latest
ports:
- "9090:9090"
environment:
LD_SUPERUSER_NAME: admin
LD_SUPERUSER_PASSWORD: change_me_to_a_long_random_password
LD_DB_ENGINE: postgres
LD_DB_HOST: db
LD_DB_PORT: 5432
LD_DB_DATABASE: linkding
LD_DB_USER: linkding
LD_DB_PASSWORD: changeme
volumes:
- linkding-data:/etc/linkding/data
depends_on:
- db
restart: unless-stopped

db:
image: postgres:16
environment:
POSTGRES_DB: linkding
POSTGRES_USER: linkding
POSTGRES_PASSWORD: changeme
volumes:
- pgdata:/var/lib/postgresql/data
restart: unless-stopped

volumes:
linkding-data:
pgdata:

Then:

docker compose up -d

Open http://localhost:9090 and log in with the superuser from the compose file.

For SQLite, remove the LD_DB_* variables and the db service. The database file then lives in /etc/linkding/data.

note

The database name variable is LD_DB_DATABASE, not LD_DB_NAME. With a wrong name, Linkding uses the default name linkding.

warning

LD_SUPERUSER_* only creates the user when no user with that name exists. Changing the password variable later does nothing. Change the password in the app under Settings.


Deploy Linkding on Hostim.dev (One-Click)​

Linkding is a self-hosted bookmark manager. With Hostim.dev, you can deploy it with Docker and managed PostgreSQL in one click, with a domain and HTTPS.

Try it Yourself

Guest project runs for 1 hour. Log in to save and extend to 5 days.

note

The template generates a random admin password at deploy time. Find it in the LD_SUPERUSER_PASSWORD environment variable of the app.

Why Host Linkding on Hostim.dev?​

  • One-click Docker deployment
  • Managed PostgreSQL, configured for you
  • Admin account with a generated password
  • /etc/linkding/data on a persistent volume, so logins survive restarts
  • Automatic HTTPS and domain
  • Real-time logs and metrics

What's included​

ResourceDetails
Appsissbruecker/linkding Docker image
DatabaseManaged PostgreSQL (LD_DB_ENGINE=postgres)
Volume/etc/linkding/data (secret key, favicons, previews)
LoginUser admin, password generated per deploy
DomainFree *.hostim.dev subdomain
SSLLet's Encrypt (auto-enabled)
Port9090

How to Deploy​

  1. Go to your Hostim.dev dashboard.
  2. Click Create Project → Use a Template.
  3. Select Linkding.
  4. Choose a resource plan.
  5. Deploy.
  6. Copy the password from the app's LD_SUPERUSER_PASSWORD environment variable.
  7. Open your app's domain, log in as admin and change the password.

FAQ​

Frequently asked questions

What is the default Linkding login?

There is none. Linkding creates an admin only when LD_SUPERUSER_NAME is set, with the password from LD_SUPERUSER_PASSWORD. Without these variables, create a user with docker compose exec linkding python manage.py createsuperuser. The Hostim template creates the user admin with a random password.

Does Linkding need PostgreSQL?

No. SQLite is the default and works well for one person. Use PostgreSQL for many users or if you already back up a PostgreSQL server. The Hostim template uses managed PostgreSQL.

Where does Linkding store its data?

Bookmarks, tags and users are in the database. /etc/linkding/data holds the SQLite file (when used), the secret key, favicons and preview images. Keep this directory on a volume.

How do I save links quickly?

Install the Linkding browser extension for Firefox or Chrome, or use the bookmarklet under Settings → Integrations. Both need your instance URL. The extension also needs an API token from the same page.

Can I import bookmarks from my browser?

Yes. Export bookmarks as an HTML file from the browser, then import it under Settings → General → Import. Tags in the file are kept.

Why do I get a CSRF error behind a reverse proxy?

Set LD_CSRF_TRUSTED_ORIGINS to your public URL, for example https://links.example.com. Linkding rejects form posts from origins it does not know.

How do I back up and update Linkding?

Back up the database (or the SQLite file in /etc/linkding/data). You can also export all bookmarks as HTML in the settings. To update with Docker, run docker compose pull && docker compose up -d. On Hostim.dev, redeploy the app. Migrations run on start.


Alternatives​

  • Karakeep (formerly Hoarder): saves full pages and uses AI for tags. Heavier to run.
  • Shiori: a small Go bookmark manager with a web archive.
  • Wallabag: read-it-later app for full articles, not bookmarks.

Source + Docs​


Looking for something else? Browse all templates →


Try it now​

Deploy Linkding Now – in less than 60 seconds