---
title: Swift SDK for iOS, macOS, tvOS, watchOS
description: Install and initialize the official InsForge Swift SDK via Swift Package Manager to use auth, database, storage, and realtime across Apple platforms.
---
import SwiftSdkInstallation from '/snippets/swift-sdk-installation.mdx';
The InsForge Swift SDK provides a native Swift client for interacting with InsForge services from iOS, macOS, tvOS, and watchOS applications.
## Installation
### Swift Package Manager
Or add it via Xcode:
1. File → Add Packages...
2. Enter: `https://github.com/insforge/insforge-swift.git`
### CocoaPods (coming soon)
```ruby
pod 'InsForge', '~> 1.0'
```
## Quick start
```swift
import InsForge
let insforge = InsForgeClient(
baseUrl: "https://your-app.insforge.app",
anonKey: "your-anon-key"
)
```
## Features
- **Database** - Type-safe CRUD operations with Codable support
- **Authentication** - Email/password and OAuth authentication
- **Storage** - File upload, download, and management
- **AI** - Chat completions and image generation
- **Realtime** - WebSocket-based pub/sub messaging
- **SwiftUI Integration** - Property wrappers and environment values
## Platform support
| Platform | Minimum Version |
|----------|----------------|
| iOS | 15.0+ |
| macOS | 12.0+ |
| tvOS | 15.0+ |
| watchOS | 8.0+ |
## SDK reference
CRUD operations with Codable models
Sign up, sign in, OAuth, and user management
File upload, download, and management
Chat completions and image generation
WebSocket pub/sub messaging