Swiftpack.co - supabase-community/supabase-swift as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by supabase-community.
supabase-community/supabase-swift 2.3.1
A Swift client for Supabase
⭐️ 529
🕓 2 weeks ago
iOS macOS watchOS tvOS macCatalyst
.package(url: "https://github.com/supabase-community/supabase-swift.git", from: "2.3.1")


Supabase client for swift. Mirrors the design of supabase-js.


Install the library using the Swift Package Manager.

let package = Package(
    dependencies: [
            url: "https://github.com/supabase-community/supabase-swift.git",
            from: "2.0.0"
    targets: [
            name: "YourTargetName",
            dependencies: ["Supabase"] // Add as a dependency

If you're using Xcode, use this guide to add supabase-swift to your project. Use https://github.com/supabase-community/supabase-swift.git for the url when Xcode asks.

If you don't want the full Supabase environment, you can also add individual packages, such as Functions, Auth, Realtime, Storage, or PostgREST.

Then you're able to import the package and establish the connection with the database.

/// Create a single supabase client for interacting with your database
let client = SupabaseClient(supabaseURL: URL(string: "https://xyzcompany.supabase.co")!, supabaseKey: "public-anon-key")

Initialize with custom options

let client = SupabaseClient(
    supabaseURL: URL(string: "https://xyzcompany.supabase.co")!, 
    supabaseKey: "public-anon-key",
    options: SupabaseClientOptions(
        db: .init(
            schema: "public"
        auth: .init(
            storage: MyCustomLocalStorage(),
            flowType: .pkce
        global: .init(
            headers: ["x-my-custom-header": "my-app-name"],
            session: URLSession.myCustomSession


  • Fork the repo on GitHub
  • Clone the project to your own machine
  • Commit changes to your own branch
  • Push your work back up to your fork
  • Submit a Pull request so that we can review your changes and merge


We are building the features of Firebase using enterprise-grade, open source products. We support existing communities wherever possible, and if the products don’t exist we build them and open source them ourselves. Thanks to these sponsors who are making the OSS ecosystem better for everyone.

New Sponsor


Stars: 529
Last commit: 2 days ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups


Release Notes

2 weeks ago

What's Changed

Full Changelog: https://github.com/supabase-community/supabase-swift/compare/2.3.0...2.3.1

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics