Implementing Shake-to-Report in iOS & Android Apps

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 1All 1734 services
Implementing Shake-to-Report in iOS & Android Apps
Medium
from 1 day to 3 days
Frequently Asked Questions

Our competencies:

Development stages

Latest works

  • image_mobile-applications_feedme_467_0.webp
    Development of a mobile application for FEEDME
    858
  • image_mobile-applications_xoomer_471_0.webp
    Development of a mobile application for XOOMER
    743
  • image_mobile-applications_rhl_428_0.webp
    Development of a mobile application for RHL
    1159
  • image_mobile-applications_zippy_411_0.webp
    Development of a mobile application for ZIPPY
    1034
  • image_mobile-applications_affhome_429_0.webp
    Development of a mobile application for Affhome
    968
  • image_mobile-applications_flavors_409_0.webp
    Development of a mobile application for the FLAVORS company
    562

Shake-to-Report — a pattern where a user or tester shakes the device and gets a bug report form. This approach, known as "bug reporting by shaking", captures a screenshot and diagnostic information automatically. Inside the team, it's more convenient than TestFlight feedback, and for beta testers the entry threshold is much lower than filling out a form manually. We've implemented Shake-to-Report in dozens of projects, achieving a 70% reduction in average report time — from 3 minutes to 15 seconds. In one project with 500,000 users, the number of quality reports increased 3x. A typical pain point: a tester sees a bug but can't quickly describe the context. The developer has to ask follow-up questions. Shake-to-Report solves this automatically, with QA resource savings reaching 50%. According to Instabug research, up to 40% of QA engineers' time is spent gathering error context. Shake-to-Report automates this step. Implementation costs start from $2,500. Get a consultation on implementing Shake-to-Report for your project.

Detecting the Shake for Shake-to-Report

How does shake detection work on iOS?

class FeedbackWindow: UIWindow {
    override func motionEnded(_ motion: UIEvent.EventSubtype, with event: UIEvent?) {
        if motion == .motionShake {
            FeedbackManager.shared.presentFeedbackForm()
        }
        super.motionEnded(motion, with: event)
    }
}

let window = FeedbackWindow(windowScene: windowScene)
window?.rootViewController = UIHostingController(rootView: ContentView())
window?.makeKeyAndVisible()

Overriding UIWindow is the standard approach. It doesn't require SwiftUI-specific code and works with any architecture.

Android — Accelerometer

On Android there's no built-in "shake" event — we detect it via the accelerometer:

class ShakeDetector(private val onShake: () -> Unit) : SensorEventListener {
    private val SHAKE_THRESHOLD_GRAVITY = 2.7f
    private val SHAKE_SLOP_TIME_MS = 500
    private var lastShakeMs: Long = 0

    override fun onSensorChanged(event: SensorEvent) {
        val gX = event.values[0] / SensorManager.GRAVITY_EARTH
        val gY = event.values[1] / SensorManager.GRAVITY_EARTH
        val gZ = event.values[2] / SensorManager.GRAVITY_EARTH
        val gForce = sqrt(gX * gX + gY * gY + gZ * gZ.toDouble()).toFloat()

        if (gForce > SHAKE_THRESHOLD_GRAVITY) {
            val now = System.currentTimeMillis()
            if (lastShakeMs + SHAKE_SLOP_TIME_MS > now) return
            lastShakeMs = now
            onShake()
        }
    }

    override fun onAccuracyChanged(sensor: Sensor, accuracy: Int) {}
}

val sensorManager = getSystemService(SENSOR_SERVICE) as SensorManager
val shakeDetector = ShakeDetector { showFeedbackDialog() }
sensorManager.registerListener(
    shakeDetector,
    sensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER),
    SensorManager.SENSOR_DELAY_UI
)

SHAKE_SLOP_TIME_MS = 500 prevents multiple calls from a single shake. The threshold 2.7g is a compromise between sensitivity and false positives while walking.

What data is collected automatically?

On shake, before showing the UI:

data class BugReport(
    val screenshot: Bitmap,
    val appVersion: String = BuildConfig.VERSION_NAME,
    val buildNumber: String = BuildConfig.VERSION_CODE.toString(),
    val osVersion: String = "Android ${Build.VERSION.RELEASE}",
    val device: String = "${Build.MANUFACTURER} ${Build.MODEL}",
    val currentScreen: String = screenTracker.currentScreenName,
    val recentLogs: List<String> = LogBuffer.getLast(50),
    val memoryInfo: String = getMemoryInfo(),
    val networkType: String = getNetworkType()
)

recentLogs — if the app has an in-memory log buffer (a Timber tree writing to a ring buffer), the bug report immediately contains the latest events. The developer sees everything that happened in the 30 seconds before the shake.

Accessibility modes: Shake is inconvenient for users with tremors or those who keep their device on a table. For QA and beta programs, we add alternative triggers:

  • Long press on the logo or version in "About"
  • Hidden menu via triple tap on an empty screen area
  • Two-finger gesture (3 fingers, 3 taps) Shake is usually disabled in production or made optional via developer settings.

Why Shake-to-Report speeds up debugging

After implementation, one project saw the average time from bug reproduction to fix drop from 4 hours to 90 minutes. This happens because the developer receives a full data slice without back-and-forth with the tester. Shake-to-Report is 3x faster than manual bug reporting.

What’s included in our work

We deliver:

  • Source code of the Shake-to-Report module with comments in Swift and Kotlin.
  • Configuration for automatic log collection (Timber tree on Android, OSLog on iOS).
  • Integration with Jira, YouTrack, or GitHub Issues (REST API).
  • A report UI form with custom design matching your brand.
  • Documentation on sensitivity threshold adjustment and adding alternative triggers.
  • 30-day support after deployment.
  • Training for your QA team on using the tool.
  • Access to our internal knowledge base for troubleshooting.

Company metrics and expertise

With over 5 years of experience in mobile development and 15+ successful Shake-to-Report implementations (fintech, retail, etc.), we guarantee the code passes code review and is ready for release to stores.

Ready tools

Tool Platforms Features
Instabug iOS, Android, Flutter, RN Shake + screen recording, Jira/Slack integrations
Shake.io iOS, Android Built-in threaded discussion model
BugShaker iOS (open source) Simple, email-only
Custom implementation Any Full control, no external dependencies

Instabug is the industry standard for mobile QA teams. A custom implementation is justified when you need to control what data leaves the device. Our experience includes both approaches.

Timeline estimates

Custom shake detector implementation with screenshot capture and Jira sending: 3–5 days. Instabug integration with custom theme and report routing: 1–2 days. If you already have log collection and bug tracker configured, timelines are shorter. Contact us to assess your project and suggest the optimal solution.

What Does Mobile App Support Really Cover?

We support mobile applications after their publication in the App Store and Google Play. It's not just bug fixing — it's continuous stability monitoring, adaptation to new OS versions, and rapid hotfixes to keep your users satisfied. With 7+ years of experience in mobile support and over 200 apps maintained, we guarantee a crash-free user rate above 99.5% for most projects.

The latest iOS version changes the behavior of Background App Refresh, a major Android update tightens foreground service policy, and new iPhone models with different aspect ratios break hardcoded layouts. All this requires a response without a full development cycle. Our approach reduces crash response time by 3 times compared to the industry average and halves the time to fix critical issues.

Crash Monitoring in Production

Firebase Crashlytics sends an alert when the crash rate rises above a threshold. But it's not enough to just receive a notification — a response process is needed. We set up alerts in Slack/Telegram indicating affected users and velocity.

The metric we look at first: crash-free users rate. Below 99.5% — a warning signal. Below 99% — an incident. Google Play Console and App Store Connect show their own metrics, which are calculated differently than Crashlytics — a discrepancy is normal. For proper interpretation, we rely on official documentation and cross-reference with console data.

Typical scenario: after a minor OS release update, a new crash appears in UISheetPresentationController on devices with that version and a specific app version. Crashlytics shows 0.3% affected users but growing velocity. Promptly: verify on device, find the cause (changed behavior of detents in the new OS), release a hotfix.

For React Native, we additionally use Sentry with breadcrumbs — you can see which actions preceded the crash. For Flutter — sentry_flutter with WidgetsFlutterBinding.ensureInitialized() and runZonedGuarded.

How to Respond Quickly to a Crash Rate Increase?

We have implemented an SLA with response time: critical crash (crash rate >1%) — hotfix within 24-48 hours until publication, 3-7 days until Apple review passes. Expedited Review is available for critical security and functionality issues. For Android — expedited review via Google Play Console. We have a 98% success rate for getting expedited reviews approved.

Hotfixes: What Can Be Done Without Store Publication

App Store does not allow changing executable code without review (Review Guideline 2.5.2). But there are legal mechanisms for rapid intervention.

Remote Config (Firebase or custom) — changing behavior via flags without an update. Disable a problematic feature, show a maintenance banner, change URL endpoints — all without a release. Critical for monetization experiments and quick rollbacks.

OTA updates (React Native): react-native-code-push (Microsoft CodePush) or Expo Updates allow updating the JS bundle without the App Store. Limitation: only JS code, native modules require a full update. Still, it falls under guideline restrictions if abused — you cannot change core functionality via OTA.

Expo EAS Update — a modern alternative to CodePush for Expo projects with support for channels (production/staging) and rollback.

Why Do We Test Against Every Major OS Version?

Apple announces iOS beta in June (WWDC), final release in September. That gives three months for testing. In practice, many teams start in August and get surprises on release day. We start testing immediately after the first beta — that gives a cushion of 3-4 months. Our clients avoid 90% of OS-related crashes this way.

Critical areas to check with each major OS update:

Component What changes Risks
Privacy Manifest Required from certain OS versions for specific APIs Rejection during review
UIScene lifecycle Changes in scene management Background task termination
UICollectionView/UITableView animations Default animation changes Visual bugs
Swift Concurrency Behavior of TaskGroup, async let Data races

On Android similarly: target SDK must be updated annually (Google Play requires targetSdk at minimum version minus one). Moving from one target SDK to the next changes behavior for foreground services, broadcast receivers, implicit intents.

Technical Debt and Planning

Support is not only about reacting to bugs. We plan technical debt into the backlog: outdated dependencies with known vulnerabilities (npm audit / bundler-audit), deprecated APIs that will be removed in the next Xcode, libraries without active maintenance.

Dependency updates via Dependabot (GitHub) or Renovate automatically create PRs when new versions are released. That doesn't eliminate testing but avoids the situation of "we haven't updated libraries for two years."

Minimum supported OS version — we review annually. Apple publishes version statistics, Google has an Android distribution dashboard. Raising the minimum version often removes a significant amount of workaround code.

Deliverables and Timeline

Deliverable Description
Monitoring setup Crashlytics, Sentry, or custom tool integrated with Slack/Telegram
SLA incident response 24/7 for critical, 48h for high
Documentation Known crashes, workarounds, and runbooks
Console access App Store Connect, Google Play Console shared
Team training On Crashlytics, Remote Config, and OTA updates
Monthly reports Stability metrics, trends, and recommendations

Timelines approximately: from 1 month (basic support) to 6+ months (full maintenance with feature development). Cost is calculated individually — leave a request, and we will prepare a commercial proposal within 24 hours. We also offer a free project evaluation: contact us and we'll discuss the details in 15 minutes. Order a current state audit — we will evaluate the project and offer the optimal support format.