Docs Getting Started Deploying with Templates

Deploying with Templates

Templates are the fastest way to get a full-stack app running on PocketBase Cloud. They include pre-configured PocketBase instances, backends, and frontends — all wired together and ready to deploy in minutes.

What are templates?

Templates are open-source GitHub repositories that follow the PocketBase Cloud project structure. Each template includes:

  • A pocketbasecloud.json config file that defines the services to deploy
  • Pre-configured PocketBase schema and collections
  • Backend code (Deno/TypeScript) with API routes and business logic
  • Frontend code (React, Vue, etc.) with authentication and UI components

When you deploy a template, PocketBase Cloud:

  1. Downloads the template from GitHub
  2. Creates all required services (PocketBase, backend, frontend)
  3. Provisions them on available servers
  4. Configures environment variables to connect everything
  5. Sets up DNS and HTTPS automatically

Available templates

SaaS Starter

A complete full-stack SaaS application with:

  • PocketBase — User authentication, database, and REST API
  • Backend — Custom API routes and business logic (Deno)
  • Frontend — User dashboard with login, signup, and account management (React)

Perfect for launching MVPs, side projects, or learning the full-stack workflow.

GitHub: pocketbasecloud/template-saas

REST API

A backend API service with database:

  • PocketBase — Database with REST API and authentication
  • Backend — API service layer with custom endpoints (Deno)

Perfect for building mobile app backends, microservices, or headless APIs.

GitHub: pocketbasecloud/template-rest-api

Prerequisites

Before deploying a template, make sure you have:

  • An active PocketBase Cloud account
  • A starter plan subscription ($5/mo with 3-day free trial) or pro plan with unlimited deployments
  • Sufficient deployment slots for the template’s services

Check your available slots on the Plan page in the dashboard.

Deploying a template

Option 1: Deploy into a new project

This creates a new project and deploys the template into it.

  1. Navigate to Projects in the sidebar
  2. Click Deploy from Template
  3. Select a template from the gallery
  4. Enter a project name (e.g., my-saas)
  5. Review the services that will be created
  6. Click Deploy

Option 2: Deploy into an existing project

This deploys the template into a project you already created.

  1. Navigate to your project from the Projects page
  2. Click Deploy Template in the project overview
  3. Select a template from the gallery
  4. Review the services that will be created
  5. Click Deploy

Provisioning process

After clicking deploy, PocketBase Cloud begins provisioning:

  1. Downloading template — Fetches the GitHub repository
  2. Creating PocketBase — Sets up your database and admin panel
  3. Creating backend — Deploys your API service
  4. Creating frontend — Deploys your UI (if included)
  5. Configuring environment — Sets up environment variables to connect services
  6. Verifying domains — Confirms DNS records are reachable

You’ll see real-time progress on the provisioning page. The entire process typically takes 2–3 minutes.

After deployment

Once provisioning is complete, you’ll see:

  • Service URLs — Direct links to your PocketBase admin panel, backend API, and frontend app
  • Admin credentials — Your PocketBase admin email and password (save these!)
  • Environment variables — Auto-configured variables like POCKETBASE_URL and PORT

Accessing your services

ServiceURL
Frontendhttps://<frontend-name>.pocketbasecloud.com
Backendhttps://<backend-name>.pocketbasecloud.com
Adminhttps://<pocketbase-name>.pocketbasecloud.com/_/

The frontend is your user-facing app. The admin panel is where you manage your database schema, collections, and records.

Managing deployed services

From the project page, you can access each deployed service:

  • PocketBase — View connection details, add custom hooks, stream logs
  • Backend — Update environment variables, redeploy code, view logs
  • Frontend — Redeploy builds, configure custom domains, view deployment history

Each service runs independently but is pre-configured to communicate with the others.

Customizing your template

After deployment, you can customize your app:

  1. Clone the GitHub repository locally
  2. Modify the code — update API routes, UI components, database schema
  3. Redeploy — upload your updated code through the dashboard

See the individual deployment guides for details:

Template configuration format

If you want to create your own template, add a pocketbasecloud.json file to your GitHub repository:

{
  "name": "My Template",
  "description": "A custom full-stack template",
  "services": {
    "pocketbase": {
      "directory": "pocketbase",
      "version": "0.34.2"
    },
    "backend": {
      "runtime": "deno",
      "startCommand": "deno task start",
      "port": 8000,
      "directory": "backend"
    },
    "frontends": [
      {
        "name": "web",
        "directory": "frontend/dist"
      }
    ]
  }
}

Each service directory should contain the necessary files:

  • pocketbase/ — PocketBase migrations and hook files
  • backend/ — Deno/TypeScript code with a main.ts entry point
  • frontend/dist/ — Built static files (HTML, CSS, JS)

Troubleshooting

Provisioning failed

If provisioning fails:

  1. Check that you have enough deployment slots on the Plan page
  2. Verify the template repository is public and accessible
  3. Review the error message on the provisioning page

Services not connecting

If your frontend can’t reach your backend:

  1. Check that environment variables are set correctly on the Backend > Env Vars page
  2. Ensure POCKETBASE_URL points to your PocketBase instance URL
  3. Verify CORS settings allow requests from your frontend domain

Admin credentials not working

If you can’t log into the PocketBase admin panel:

  1. Find the credentials on the PocketBase detail page
  2. Try resetting the password through the admin panel’s “Forgot password” link
  3. Check the PocketBase logs for authentication errors

Next steps

Now that your template is deployed:

  • Explore the admin panel — Create collections, manage users, test the API
  • Update environment variables — Add API keys, configure external services
  • Set up custom domains — Point your own domain to your deployments
  • Review the code — Clone the template repo and explore how it works

Ready to go beyond templates?