Silent Push Notifications in Mobile App

TRUETECH is engaged in the development, support and maintenance of iOS, Android, PWA mobile applications. We have extensive experience and expertise in publishing mobile applications in popular markets like Google Play, App Store, Amazon, AppGallery and others.
Development and support of all types of mobile applications:
Information and entertainment mobile applications
News apps, games, reference guides, online catalogs, weather apps, fitness and health apps, travel apps, educational apps, social networks and messengers, quizzes, blogs and podcasts, forums, aggregators
E-commerce mobile applications
Online stores, B2B apps, marketplaces, online exchanges, cashback services, exchanges, dropshipping platforms, loyalty programs, food and goods delivery, payment systems.
Business process management mobile applications
CRM systems, ERP systems, project management, sales team tools, financial management, production management, logistics and delivery management, HR management, data monitoring systems
Electronic services mobile applications
Classified ads platforms, online schools, online cinemas, electronic service platforms, cashback platforms, video hosting, thematic portals, online booking and scheduling platforms, online trading platforms

These are just some of the types of mobile applications we work with, and each of them may have its own specific features and functionality, tailored to the specific needs and goals of the client.

Showing 1 of 1 servicesAll 1735 services
Silent Push Notifications in Mobile App
Medium
from 1 business day to 3 business days
FAQ
Our competencies:
Development stages
Latest works
  • image_mobile-applications_feedme_467_0.webp
    Development of a mobile application for FEEDME
    756
  • image_mobile-applications_xoomer_471_0.webp
    Development of a mobile application for XOOMER
    624
  • image_mobile-applications_rhl_428_0.webp
    Development of a mobile application for RHL
    1054
  • image_mobile-applications_zippy_411_0.webp
    Development of a mobile application for ZIPPY
    947
  • image_mobile-applications_affhome_429_0.webp
    Development of a mobile application for Affhome
    862
  • image_mobile-applications_flavors_409_0.webp
    Development of a mobile application for the FLAVORS company
    445

Implementing Silent Push Notifications in Mobile Apps

Silent push — a notification without sound, without banner, without user interaction. It arrives in the background, wakes the app, gives it several seconds to execute code. Used for background content sync, cache invalidation, updating badge counter without opening the app.

iOS: Background Fetch Through Silent Push

On iOS, silent push requires two things: the content-available: 1 flag in payload and enabled Background Mode "Remote notifications" in Xcode Capabilities.

APNs Payload:

{
  "aps": {
    "content-available": 1
  },
  "sync_type": "messages",
  "last_known_id": "msg_8823"
}

No alert, no sound — pure background call. iOS will invoke:

func application(_ application: UIApplication,
                 didReceiveRemoteNotification userInfo: [AnyHashable: Any],
                 fetchCompletionHandler completionHandler: @escaping (UIBackgroundFetchResult) -> Void) {
    guard let syncType = userInfo["sync_type"] as? String else {
        completionHandler(.noData)
        return
    }

    Task {
        do {
            let hasNewData = try await SyncManager.shared.sync(type: syncType)
            completionHandler(hasNewData ? .newData : .noData)
        } catch {
            completionHandler(.failed)
        }
    }
}

Critical point: iOS gives about 30 seconds to execute. If completionHandler is not called in that time — iOS forcefully terminates the background task. Also, iOS doesn't guarantee silent push delivery at low battery (Low Power Mode) or when user force-quit the app.

Force quit is the main pain. Force quit through iOS task switcher completely blocks silent push until the next manual app open. This is documented behavior, can't be bypassed.

Android: FCM Data Message and WorkManager

Android has no direct equivalent of "silent push" — there's FCM Data Message, which always lands in FirebaseMessagingService.onMessageReceived regardless of app state (provided the app isn't killed by system Doze).

class AppFirebaseMessagingService : FirebaseMessagingService() {
    override fun onMessageReceived(message: RemoteMessage) {
        val syncType = message.data["sync_type"] ?: return

        // Run WorkManager task — short, with execution guarantee
        val workRequest = OneTimeWorkRequestBuilder<SyncWorker>()
            .setInputData(workDataOf("sync_type" to syncType))
            .setExpedited(OutOfQuotaPolicy.RUN_AS_NON_EXPEDITED_WORK_REQUEST)
            .build()

        WorkManager.getInstance(applicationContext).enqueue(workRequest)
    }
}

setExpedited() — request for immediate execution. Android 12+ requires setForegroundAsync inside expedited worker or foreground service, otherwise ANR on long operation.

Doze Mode — Android restricts background activity on unplugged devices. FCM uses high-priority messages to bypass Doze, but you need to explicitly set priority: "high" when sending through FCM:

{
  "message": {
    "token": "device_fcm_token",
    "android": {
      "priority": "HIGH"
    },
    "data": {
      "sync_type": "messages",
      "payload": "{...}"
    }
  }
}

Usage for Badge Counter

A popular use case — update the icon number without showing a notification:

// iOS — through silent push
func application(_ application: UIApplication,
                 didReceiveRemoteNotification userInfo: [AnyHashable: Any],
                 fetchCompletionHandler completionHandler: @escaping (UIBackgroundFetchResult) -> Void) {
    if let badge = userInfo["badge"] as? Int {
        UNUserNotificationCenter.current().setBadgeCount(badge) { _ in }
    }
    completionHandler(.newData)
}

On Android badge is updated through ShortcutBadger (third-party library) or through NotificationManagerCompat with setNumber(). There's no unified API — each launcher (Samsung, Xiaomi, Huawei) has its own mechanism.

Limitations and Quota

iOS 13+ introduced BGTaskScheduler and background processing quota. If the app too frequently requests background execution and doesn't provide user benefit (according to iOS) — the system starts throttling calls. Returning .noData from completionHandler in response to silent push where there's no data — important for correct quota system operation.

Timeframe

Setting up silent push for iOS (Background Modes, handler) and Android (FCM Data Message + WorkManager), covering edge cases (Doze, force quit, quota) — 3–5 working days.