## Context
Self-hosting fails on startup with Prisma `Error: P1013: The provided database string is invalid` when the DATABASE_URL contains special characters in the username/password (e.g. `@`, `:`, `/`).

## Verified resolution
Maintainer Steffen911: the fix is to percent-encode the special characters in the username/password of DATABASE_URL, e.g. the connection string with special characters percent-encoded in the username and password (e.g. `@` written as `%40`, `:` as `%3A`), and guard against double-encoding (only encode when no `%XX` sequences are present). He also moved the detection into the web container entrypoint via PR #13186 so bad URLs now raise a clear startup warning instead of an opaque P1013.