Getting Started

PSPDFKit Server is the backend for PSPDFKit clients. It is distributed as a Docker container.

We recommend using Docker Machine, Kubernetes, or native Docker support by a cloud provider like Amazon Web Services, Google Cloud Platform, or Microsoft Azure for deployment in production.

ℹ️ Note: If you just want to get an example up and running quickly, use the preconfigured Docker setup from our Example Projects.

The steps below outline how to get a simple setup on a single host up and running via docker-compose.

  1. Make sure you have Docker installed and running.

    On macOS we recommend the most recent version of Docker for Mac.

    On Windows we recommend the most recent version of Docker for Windows.

  2. Pull the pspdfkit image from Docker Hub:

    docker pull pspdfkit/pspdfkit

    ℹ️ Note: The PSPDFKit Server image has been hosted on DockerHub since version 2019.1.0. The previous Docker registry at is deprecated. If you have specific requirements or need access to older versions, please reach out to our support team.

  3. Create the following docker-compose.yml file somewhere on your file system:

    version: '3.8'
        image: postgres:11.6
          POSTGRES_USER: pspdfkit
          POSTGRES_PASSWORD: password
          POSTGRES_DB: pspdfkit
          POSTGRES_INITDB_ARGS: --data-checksums
          PGDATA: /var/lib/postgresql/data/pgdata
          - pgdata:/var/lib/postgresql/data
        image: pspdfkit/pspdfkit:latest
          PGUSER: pspdfkit
          PGPASSWORD: password
          PGDATABASE: pspdfkit
          PGHOST: db
          PGPORT: 5432
          # Uncomment the following line if your custom PostgreSQL
          # installation requires TLS. The default value is `false`.
          # PGSSL: true
          # Activation key for your PSPDFKit Server installation.
          # Secret token used for authenticating API requests.
          API_AUTH_TOKEN: secret
          # Base key used for deriving secret keys for the purposes of authentication.
          SECRET_KEY_BASE: secret-key-base
          # Public key used for verification of JWTs from web clients. It has to be in the PEM format.
          JWT_PUBLIC_KEY: |
            -----BEGIN PUBLIC KEY-----
            -----END PUBLIC KEY-----
          JWT_ALGORITHM: RS256
          # Credentials to access the admin dashboard.
          DASHBOARD_USERNAME: dashboard
          DASHBOARD_PASSWORD: secret
          - 5000:5000
        - db
  4. In a terminal tab, navigate to the directory where you’ve placed the docker-compose.yml file and execute the following:

    docker-compose up

    Make sure that navigating to http://localhost:5000/dashboard in a web browser shows the dashboard, which can be accessed with the username dashboard and the password secret (you can configure these values using the environment variables in the docker-compose.yml file).

    You can quit the running containers with Ctrl-C.

  5. Now follow the guides to integrate PSPDFKit for Web into your app’s frontend and backend.

Take a look at our Troubleshooting guides for solutions to common issues.