A Flutter plugin that allows you to add an inline webview, to use an headless webview, and to open an in-app browser window.
- Official documentation: inappwebview.dev/docs
- Read the online API Reference to get the full API documentation.
- Official blog: inappwebview.dev/blog
- Find open source projects on the Official Showcase page: inappwebview.dev/showcase
- Check the flutter_inappwebview_examples repository for project examples
- Check the flutter_inappwebview/example/integration_test/webview_flutter_test.dart file for other code examples
- Flutter Browser App: A Full-Featured Mobile Browser App (such as the Google Chrome mobile browser) created using Flutter and the features offered by the flutter_inappwebview plugin
Check the Showcase page to see an open list of Apps built with Flutter and Flutter InAppWebView.
Send a submission request to the Submit App page!
- Dart sdk: "^3.8.0"
- Flutter: ">=3.32.0"
- Android:
minSdkVersion >= 19, AGP version>= 7.3.0(use Android Studio - Android Gradle plugin Upgrade Assistant for help) - iOS 12.0+, Xcode version
>= 15.0 - MacOS 10.14+: Xcode version
>= 15.0 - Windows: NuGet CLI available on your PATH environment variable
- Linux: WPE 2.0 WebKit built
This fork is distributed from Git. Its platform packages use sibling path
dependencies so the API and native implementations come from the same commit.
They are marked publish_to: none; publishing separate packages requires
replacing those paths with compatible published versions first.
dependencies:
flutter_inappwebview:
git:
url: https://github.com/Otzaria/flutter_inappwebview.git
ref: master # Prefer a tested commit SHA in production.
path: flutter_inappwebviewDo not combine these packages with overrides pointing to published platform implementations or a different Git revision.
Call await WebViewEnvironment.prewarm() before creating the first WebView to
prepare supported startup work asynchronously. Prewarming is optional: failures
are returned as results, and unsupported platforms return null.
| Platform | Behavior |
|---|---|
| Windows | Loads WebView2 through a temporary environment on a background STA. Pass the same environment settings to prewarm and the later create. Concurrent identical calls share work; completed results are not cached. |
| Android | Uses AndroidX 1.14's experimental startup API with UI tasks disabled. Apply ProcessGlobalConfig first. Only background startup work is warmed; the first WebView still performs UI initialization. Windows settings are ignored. The first outcome is reused within the engine. |
| Linux | prewarm returns null. An explicit WebViewEnvironment.create() can prepare and retain the WebKit context for later views. |
| iOS, macOS, Web | prewarm returns null. |
Native startup has a 30-second deadline, with a Dart reply timeout of 31 seconds on Windows and 35 seconds on Android. Provider initialization cannot be interrupted, so its worker may continue after a timeout. Prewarming does not guarantee that subsequent view creation will avoid all startup costs.
Add flutter_inappwebview as a dependency in your pubspec.yaml file.
Did you find this plugin useful? Please consider to make a donation to help improve it!
Thanks goes to these wonderful people (emoji key):
This project follows the all-contributors specification. Contributions of any kind welcome!
