Skip to content
pubscout

signalr_flutter

0.2.1, released a year ago by ayan.asdevs.dev

Flutter plugin for ASP.NET SignalR client

WASM-ready
$ flutter pub add signalr_flutter
Source repository

What it does

Provides a client to connect to an ASP.NET SignalR hub, subscribe to hub methods, and invoke server methods using string arguments and results.

AI-written summary of version 0.2.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • Need real‑time communication with an ASP.NET SignalR server
  • Only string data is required for messages and method arguments
  • Running on Android or iOS with native SignalR support

Skip it when

  • Using .NET Core SignalR server
  • Needing complex or typed payloads
  • Requiring advanced transport customization beyond the plugin

Strengths

  • Simple API with connect, invokeMethod, and callbacks
  • Supports both Android and iOS, including cleartext traffic and ProGuard rules
  • Generic invokeMethod allows any number of string arguments

Weaknesses

  • Only string arguments and return values supported
  • Not compatible with .NET Core SignalR
  • Limited to ASP.NET SignalR features

Setup

Kind
Plugin (native code)
Effort
Low
Code generation
No
Direct dependencies
0

Add <application android:usesCleartextTraffic="true"> for HTTP URLs and keep class microsoft.aspnet.signalr.client.hubs.** { *; } in proguard-rules.pro for release builds

SignalR signalR = SignalR(
  '<Your server url here>',
  "<Your hub name here>",
  hubMethods: ["<Your Hub Method Names>"]
  statusChangeCallback: (status) => print(status),
  hubCallback: (methodName, message) => print('MethodName = $methodName, Message = $message'));
signalR.connect();

Alternatives

Packages that do the same job and could replace signalr_flutter.

  • signalr_netcore

    Flutter client for ASP.NET Core SignalR supporting WebSocket, SSE, LongPolling and MessagePack.

  • signalr_core

    Client for ASP.NET Core SignalR, supports WebSocket and SSE across Dart platforms

  • vmodal_sdk_flutter

    Typed VModal API client for Flutter to upload videos and search moments by meaning.

  • sync_http

    Synchronous HTTP client for Dart using RawSynchronousSockets.