If you’re following the Implementation Outline: after configuring your database, connecting your PowerSync instance to it, and defining basic Sync Rules, the next step is to include the appropriate PowerSync Client SDK package in your app project. On a high level, this involves the following steps:
The PowerSync Client SDKs expose a managed SQLite database that your app can read from and write to. The client-side schema refers to the schema for that SQLite database.
This allows write operations on the client-side SQLite database to be uploaded to your backend and applied to your backend database.
Integrating with your backend is also part of authentication integration. For initial development and testing, you can use Development Tokens, and then implement proper authentication integration at a later time.
For async iterator support with watched queries, additional polyfills are required. See the Babel plugins section in the README.
By default, this SDK connects to a PowerSync instance via WebSocket (from @powersync/react-native@1.11.0) or HTTP streaming (before @powersync/react-native@1.11.0). See Developer Notes for more details on connection methods and platform-specific requirements.
See the full SDK reference for further details and getting started instructions:
This SDK currently requires @journeyapps/wa-sqlite as a peer dependency. Install it in your app with:
Copy
npm install @journeyapps/wa-sqlite
Copy
npm install @journeyapps/wa-sqlite
Copy
yarn add @journeyapps/wa-sqlite
Copy
pnpm install @journeyapps/wa-sqlite
By default, this SDK connects to a PowerSync instance via WebSocket (from @powersync/web@1.6.0) or HTTP streaming (before @powersync/web@1.6.0). See Developer Notes for more details on connection methods.
See the full SDK reference for further details and getting started instructions:
Add the PowerSync SDK to your project by adding the following to your build.gradle.kts file:
Copy
kotlin { //... sourceSets { commonMain.dependencies { api("com.powersync:core:$powersyncVersion") // If you want to use the Supabase Connector, also add the following: implementation("com.powersync:connectors:$powersyncVersion") } //... }}
CocoaPods configuration (recommended for iOS)
Add the following to the cocoapods config in your build.gradle.kts:
The @powersync/better-sqlite package requires native compilation, which depends on certain system tools. This compilation process is handled by node-gyp and may fail if required dependencies are missing or misconfigured.