Capacitor wraps web apps so one JavaScript codebase can ship to iOS, Android, and the mobile web. It bridges web code to native SDKs through plugins.
Overview
Capacitor is a native runtime for building web-based apps that also target app stores and Progressive Web Apps. Developers keep HTML, CSS, and JavaScript while gaining cross-platform APIs for device features.
It drops into existing modern web projects via npm, then adds native platform packages for iOS and Android. Native projects are treated as source artifacts you maintain, and a plugin API exposes device capabilities such as camera, geolocation, local notifications, filesystem access, and network status.
Plugin authors can write Swift on iOS and Kotlin or Java on Android, either inside an app or as shared npm packages. Cordova plugin compatibility is supported for many existing plugins, and Ionic Framework is optional for UI and tooling.
Official plugins cover camera capture, file storage, accelerometer data, haptics, and custom extensions. Teams commonly pair Capacitor with React, Vue, Svelte, Angular, or other web frameworks when moving a site into store builds.
Key features
- Single codebase for iOS, Android, and PWA
- Cross-platform native plugin APIs
- Custom native plugin development
- Cordova plugin compatibility layer
- Core plugins for camera and geolocation
- Local notifications and filesystem access
- npm-based project initialization
- Works without Ionic Framework
Use cases
- Shipping a web app to mobile stores
- Accessing device APIs from JavaScript
- Migrating Cordova-based projects
- Building offline-capable hybrid apps