IMGDD is a simple, self-hostable image hosting program.
It powers an image hosting project that began in early 2023. After some users requested the source code, I decided to make it available following a bit of refactoring and cleanup.
As of February 2025, the project handles over 1 TB of traffic and 4.2 million requests per day. Since continued growth may force me to stop accepting new images, I open-sourced IMGDD so that anyone can run their own instance and serve their images.
replicate CLI command.canonical (proxied from the best available backend) and direct (routed through a specific backend); per-image delivery chooses the highest-priority enabled backend.@captchaProtected directive.@isAuthenticated / @isSiteOwner directives.window.registerPlugin API lets custom JS inject content into named UI slots without rebuilding the frontend.ALLOW_UPLOAD) or new user signups (ALLOW_NEW_USER) at runtime.gql, jet, reset-db, dev-server with hot reload).If you use nix, you can just do
nix develop.
Copy the environment file and adjust if needed:
bash
cp .env.template .env
Start local services (PostgreSQL, Redis, MinIO ancient version):
bash
docker compose up -d
Run database migrations:
bash
go run . migrate
Populate built-in roles:
bash
go run . populate-built-in-roles
Create a user:
bash
go run . create-user --email you@imgdd.com --password yourpassword --is-site-owner
Install pre-commit hooks if you plan to contribute:
bash
lefthook install
# Build the frontend
cd web_client && pnpm install && pnpm build && cd ..
# Start the server
go run . serve
# Start with auto-reload (requires air)
go run . dev-server
Dev commands are available when running from source:
# Regenerate GraphQL code (gqlgen)
go run . gql
# Regenerate Jet ORM code (requires running PostgreSQL)
go run . jet
# Regenerate frontend GraphQL types
cd web_client && pnpm gen
# Run migrations
go run . migrate
# Migrate to a specific version
go run . migrate --version 3
# Create a new migration file
go run . make-migration --name add_some_table
# Reset the database (dev only)
go run . reset-db
All commands accept a -c / --config flag to specify the config file path, and a --log-level flag (default: info).
See FAQ in the Wiki.
$ claude mcp add imgdd \
-- python -m otcore.mcp_server <graph>