Skip to main content
Firebase Crashlytics is a real-time crash reporting solution that helps you identify, prioritize, and resolve the most critical issues affecting your app users. This plugin integrates the iOS and Android Firebase Crashlytics SDKs into your app and supports logging of native crashes, WebView console errors, and (on Android) toast errors.

Why use Google Firebase Crashlytics

  • App crash events: Native crash reporting.
  • WebView console errors: WebView console errors logged to Crashlytics.
  • Android toast errors: Android-only (for example, SSL certificate warnings).
  • Runtime control: Enable/disable log collection and set user IDs via the Median JavaScript Bridge.

Prerequisites

  • A Median app with the JavaScript Bridge enabled
  • Firebase project with Crashlytics enabled
  • GoogleService-Info.plist (iOS) and google-services.json (Android) from Firebase Console
  • Plugin purchased and enabled in Median App Studio

When to use this plugin

Use Firebase Crashlytics if your app needs to:

Integration guide

Enable the plugin

  1. Navigate to Native Plugins: Open your app in Median App Studio and go to the Native Plugins section.
  2. Enable Firebase Crashlytics: Select Google Firebase Crashlytics from your list of purchased plugins and enable it.
  3. Configure log collection: Use the options below to customize which logs are collected.
Google Firebase Crashlytics plugin enabled in the Native Plugins section of App Studio

Enable Firebase Crashlytics in App Studio

Configuration options

Toggle the options as needed, then click Advanced Mode for further configuration.
Crashlytics log collection toggles in the plugin settings

Enable or disable specific log types

App configuration

  1. Register your app in the Firebase Console.
  2. Download the configuration files:
    1. Android: google-services.json
    2. iOS: GoogleService-Info.plist
  3. Upload GoogleService-Info.plist (iOS) and google-services.json (Android) in App Studio under Build & Deploy → Google Services. You can upload the files from Firebase or copy and paste their contents into App Studio.
For full instructions, refer to the official Firebase setup guides:

Use your AI agent

Use the Median MCP with your AI agent to enable Firebase Crashlytics and add your Firebase configuration files to your mobile app. See Median MCP server to set it up.

Finalizing the app build

Once the configuration files are uploaded, save the changes and rebuild your app.
Uploading Firebase configuration files under Build & Deploy in App Studio

Upload your GoogleService-Info.plist and google-services.json configurations

JavaScript Bridge functions

The Median JavaScript Bridge allows you to control Crashlytics at runtime.

Enable/disable logs collection

Enable or disable Crashlytics log collection at runtime.
Parameters:

Set user ID

Assign a custom user ID to track crash logs per user in Firebase. Persists between app launches; cleared on uninstall/reinstall.

Unset user ID

Remove the previously set user ID.
To comply with privacy policies or regulations, you can ask users for permission before collecting logs. Enable the permission prompt by setting requestOptIn to true in the plugin configuration. Users will see a permission dialog on first app launch after installation.
Permission dialog asking the user to allow log collection

Request user opt-in for log collection

Testing checklist

Use this checklist to verify Crashlytics is configured and logging as expected:

Basic functionality

  • Firebase Crashlytics plugin is enabled in App Studio
  • GoogleService-Info.plist (iOS) and google-services.json (Android) are uploaded in Build & Deploy → Google Services
  • App is rebuilt after saving configuration changes
  • median.firebaseCrashlytics.enable(true) enables log collection at runtime

Platform testing

  • median.firebaseCrashlytics.webErrorLogsEnabled(true/false) updates WebView error logging behavior
  • median.firebaseCrashlytics.toastErrorLogsEnabled(true/false) updates Android toast error logging behavior

Configuration testing

  • median.firebaseCrashlytics.setUserId('user_123') sets a user identifier for crash logs
  • median.firebaseCrashlytics.unsetUserId() removes the user identifier
  • If requestOptIn is enabled, the permission prompt appears on first app launch after install

User experience

  • Open https://median.dev/crashlytics inside your app and confirm logs/events are received in Firebase Crashlytics
  • Consent prompt (if used) appears at an appropriate time and copy matches your policy

Troubleshooting

Crashlytics functions are undefined or not working

Ensure the JavaScript Bridge is enabled in App Studio and that you call functions after the median_library_ready() event. Verify the plugin is enabled and GoogleService-Info.plist (iOS) and google-services.json (Android) are uploaded in Build & Deploy → Google Services.

Logs do not appear in Firebase Crashlytics

Confirm the app was rebuilt after uploading Google services files and saving plugin settings. Also verify log collection is enabled with median.firebaseCrashlytics.enable(true) and that the correct Firebase project files were uploaded for each platform.

WebView errors are not being captured

Check that webErrorLogsEnabled is enabled in plugin settings (and at runtime if you manage it dynamically).

Android toast errors are not being captured

toastErrorLogsEnabled applies to Android only. Ensure it is enabled in settings and test on an Android build. The prompt only appears when requestOptIn is enabled and is shown on first launch post-installation. Reinstall the app to retest first-launch behavior.
Still having trouble?For Firebase Crashlytics issues outside Median, refer to the Firebase Crashlytics documentation.
Last modified on December 3, 2026