What is Azure Web PubSub?
Azure Web PubSub is a fully managed real-time messaging service that provides WebSocket connections for web, mobile, and server applications. The service handles all connection management and automatically scales to millions of concurrent connections. Web PubSub supports native WebSocket protocols and custom subprotocols for structured communication.
Unlike Azure SignalR Service, which provides an abstraction for .NET developers, Web PubSub is a low-level service for any language and any client that supports WebSockets.
Key Features
- Native WebSockets: Standard WebSocket protocol without proprietary client libraries
- Publish-Subscribe: Group-based messaging for efficient broadcasts to thousands of clients
- Event Handlers: Serverless integration with Azure Functions for incoming messages
- Client Permissions: Granular access control via JWT-based authentication
- Automatic Scaling: Elastic capacity without manual provisioning
Typical Use Cases
Live Dashboards: Real-time updates for monitoring dashboards, stock prices, or gaming leaderboards.
Collaborative Apps: Multi-user editors, whiteboards, or project management tools with live synchronization.
Live Notifications: Push notifications for social media feeds, chat applications, or alert systems.
Benefits
- No Server Infrastructure: Fully managed with automatic scaling and patches
- Platform Independent: Standard WebSocket for browsers, mobile apps, and IoT devices
- Serverless Integration: Native integration with Azure Functions for event-driven architectures
- Cost-effective: Pay-per-message model without minimum commitment
Frequently Asked Questions about Azure Web PubSub
What is the difference from Azure SignalR Service?
SignalR Service is optimized for .NET developers with the SignalR library and offers features like automatic reconnect and fallback protocols. Web PubSub is a low-level WebSocket service for any language without proprietary dependencies.
How many concurrent connections are supported?
One Standard unit supports 1,000 concurrent connections. You can scale up to 100 units for 100,000 connections. For more capacity, multiple instances can be combined.
How do I authenticate clients?
Web PubSub uses JWT tokens for authentication. Your server generates tokens with specific claims for user ID, group membership, and permissions (send, receive, join).
Which protocols are supported?
Native WebSocket (ws/wss) is the standard. Additionally, there is the json.webpubsub.azure.v1 subprotocol for structured messages with system events and acknowledgements.
How do I integrate with Azure Functions?
Web PubSub provides Azure Functions bindings for triggers (incoming messages) and output (sending messages). You can implement serverless event handlers without your own server infrastructure.
Integration with innFactory
As a Microsoft Solutions Partner, innFactory supports you with Azure Web PubSub: from real-time application architecture to integration with existing backends to implementing scalable messaging solutions.
