Azure Notification Hubs provides the infrastructure between an application backend and platform notification systems such as Apple Push Notification service (APNs) and Firebase Cloud Messaging (FCM). The backend submits notifications to a hub, which resolves the target devices and forwards the appropriate payloads to those providers. Notification Hubs is not a replacement for platform push services: applications still need platform credentials, device tokens, notification permissions, and client-side handling.
Resources are organized into namespaces and hubs. A namespace is a regional management and billing boundary containing one or more hubs. A hub holds the push configuration and device information for an application environment. Separate production and test hubs so that credentials, device registrations, and test broadcasts do not affect production users. Select the namespace tier according to device capacity, push volume, and required features.
For new implementations, prefer the installations API for device management. An installation associates a stable installation identifier with a platform push handle, tags, and optional templates. Its create-or-update behavior is idempotent, making registration retries easier to implement without creating duplicate records. Refresh the installation when the platform rotates a device token, and update user associations when someone signs in or out. Existing applications can also use the registrations API.
Audience selection uses tags and tag expressions. A backend can assign tags representing a user, subscription, language, or business segment, then send to matching installations without enumerating every device. Tags are routing metadata, not an authorization boundary. Validate requested subscriptions and assign sensitive user or tenant tags on a trusted backend rather than accepting arbitrary client-provided values.
Send native platform payloads when you need explicit control over platform behavior, or use templates to map common application properties into different payload formats. For Android applications using FCM, configure FCM v1 credentials and payloads rather than the retired legacy HTTP integration. For Apple notifications, set headers such as apns-push-type consistently with the payload and intended alert or background behavior.
Keep notification sending and management credentials on the backend. Use narrowly scoped Shared Access Signature policies for application operations, store secrets securely, and rotate keys through a controlled deployment process. Azure resource management authentication is distinct from the credentials used to register devices and submit notifications.
Design push notifications as best-effort signals rather than durable records of business events. Acceptance by Notification Hubs or a downstream provider does not prove that a device displayed a notification, and there is no end-to-end delivery latency guarantee. Persist authoritative application state separately, include an opaque event identifier or deep link in the notification, and let the authenticated client retrieve current data. Monitor submission failures, provider errors, and throttling, and implement bounded retries without assuming that duplicate notifications are impossible.