Skip to content

Proposal: PocketBase add-on #527

Open

Description

@akanyane

Proposal

Add a built-in PocketBase add-on for React (--add-ons pocketbase).

PocketBase is an open source backend in a single binary: embedded SQLite, auth, realtime subscriptions, file storage and an admin UI. It's a popular choice for side projects and self-hosted apps, and right now the CLI has no self-hosted backend option in the database category (Neon, Convex and PowerSync are all hosted services).

Scope

It follows the same shape as the existing Convex / PowerSync add-ons:

  • pocketbase JS SDK dependency + src/lib/pocketbase.ts client reading VITE_POCKETBASE_URL
  • a pb_migrations/ JS migration that creates a todos collection on ./pocketbase serve
  • pb_data/ added to .gitignore
  • a /demo/pocketbase realtime todo route using the standard demo-* styles
  • category database, exclusive with database / orm, React + Vite only

The user downloads the PocketBase binary themselves (same manual-backend model as the Strapi add-on).

I have a working implementation ready and tested against a real PocketBase v0.40.6 server. Would you be open to this? Happy to adjust scope or naming.

Activity

  1. tannerlinsley commented on Nov 6, 2026

    @tannerlinsley
    Member

    Thanks for putting this together! Could you link the implementation or open a draft PR so we can review what you already have?

    AI review notes:
    Please include the SDK and PocketBase server versions used, the generated migration, and how collection permissions keep one user from reading or changing another user’s todos. Local setup and test commands would help us verify the integration without contacting a hosted backend. We can preserve your implementation and credit rather than build a competing add-on.

  2. akanyane commented on Nov 6, 2026

    @akanyane
    Author

    Thanks! Draft PR is up: #572

    It has what you asked for:

    • Versions: PocketBase server v0.40.6 and JS SDK ^0.28.2.
    • Migration: pb_migrations/1761955200_created_todos.js.
    • Permissions: my first version had public rules, so I changed it after your question. Todos now have a required owner relation, and the collection's API rules restrict list, view, update, delete and realtime events to the owner. The create and update rules also stop a user from creating a todo for someone else or handing one over.
    • Local setup and tests: the commands are in the PR, along with a script that checks these permissions against a local PocketBase server.

    The PR lists what I ran. I don't have branded Chrome, so I ran the E2E suite on headless Chromium with a local config.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions