connectivity_plus
7.3.2, released 7 weeks ago by fluttercommunity.dev
Discover the state of network connectivity (WiFi, mobile, ethernet) on Android, iOS, Web and desktops.
What it does
Allows Flutter applications to check the current network connectivity status and listen to connection changes in real-time. It supports various connection types such as mobile, Wi-Fi, ethernet, VPN, bluetooth, and satellite across multiple platforms.
AI-written summary of version 7.3.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to detect if the device is connected to Wi-Fi, cellular, or other networks
- Your app needs to react to network connection state changes via a stream
Skip it when
- You are relying solely on connectivity status to guarantee actual internet access or reachability
- You need detailed Wi-Fi SSID or MAC address details on platforms where privacy restrictions block it
Strengths
- Cross-platform support including Android, iOS, Web, macOS, Windows, and Linux
- Provides both a one-time check and a real-time event stream
- Flutter favorite package with regular updates
Weaknesses
- Connection type availability does not guarantee actual internet access
- Web implementation has browser limitations and relies on experimental APIs or fallback to online status
- Background connectivity changes are not communicated on Android O and above
Setup
- Kind
- Plugin (native code)
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 5
Requires minimum Flutter >=3.19.0, Dart >=3.3.0, iOS >=13.0, macOS >=10.15, and Java 17.
import 'package:connectivity_plus/connectivity_plus.dart';
final List<ConnectivityResult> connectivityResult = await (Connectivity().checkConnectivity());
if (connectivityResult.hasConnectivity) {
// Connectivity available
}Alternatives
Packages that do the same job and could replace connectivity_plus.
- network_info_plus
Flutter plugin for discovering network and WiFi details.
92Compare - connectivity_control
Inspects active network interfaces, internet capability, validation, metering, and bandwidth.
73Compare - battery_plus
Access device battery level, state, and battery save mode across platforms.
93Compare - internet_connection_checker_plus
Verifies actual internet connectivity by checking reachability against global endpoints.
82Compare
Works with
Packages commonly used together with connectivity_plus: ones it builds on, ones built on it, and its own family.
- webconnectivity_plus depends on itLightweight bindings for browser APIs via JS interop
- nmconnectivity_plus depends on itClient for interacting with Linux NetworkManager via D-Bus
- background_downloaderBuilt on connectivity_plusMulti-platform background file downloading and uploading for Flutter.
- livekit_clientBuilt on connectivity_plusFlutter Client SDK for LiveKit to build real-time video, audio, and data features.
- graphql_flutterBuilt on connectivity_plusA GraphQL client for Flutter with widget wrappers and hooks.
- stream_chat_flutter_coreBuilt on connectivity_plusCore Flutter SDK for Stream Chat providing business logic and controllers without UI.
- launchdarkly_flutter_client_sdkBuilt on connectivity_plusOfficial LaunchDarkly client-side feature flag SDK for Flutter.
- internet_connection_checkerBuilt on connectivity_plusVerifies active internet connectivity and detects slow connections by checking accessible URIs.