Firebase Destination Config Reference
Beta- free
- growth
- enterprise
4 minute read
Firebase is a mobile analytics destination that runs only in device mode. RudderStack’s mobile SDKs load the Firebase SDK in the app and log identify, track, and screen calls to Google Analytics for Firebase from there, mapping track events to Firebase’s standard events where they match.
In a Firebase destination spec:
type: firebasedefinition_version: 1
Sample configuration
version: rudder/v1
kind: destination
metadata:
name: firebase-prod
spec:
id: firebase-prod
display_name: Firebase Production
type: firebase
definition_version: 1
enabled: true
config:
event_filtering:
blacklist:
- Application Backgrounded
- Debug Event
connection_mode:
android_kotlin: device
ios_swift: device
consent_management:
android_kotlin:
- provider: oneTrust
consents:
- analyticsThe above example connects Kotlin and Swift apps. The Firebase project itself isn’t configured here — the app bundles it, in the google-services.json or GoogleService-Info.plist file Firebase generates — so event_filtering is the only Firebase-specific key. See Event filtering.
Config keys
config accepts only the keys listed below. The shared config key rules cover unknown keys, defaults, and immutability.
Firebase runs only indevicemode. The mobile SDKs send itidentify,track, andscreencalls from the app, so every key below configures what the SDK does in the app.
Event filtering
Every source connects to Firebase in device mode, where the SDK applies the filter, so client-side event filtering applies to track events from every source.
event_filtering
Type:
object
Description:
Restricts which track events the SDK passes to Firebase, by event name.
Notes:
whitelist— array of event names to allow; every othertrackevent is dropped.blacklist— array of event names to drop; every othertrackevent is allowed.- The two are mutually exclusive, and Rudder CLI enforces it — setting both fails validation.
- Each name is at most 100 characters, or a
{{ path || fallback }}template. - Omit the block entirely to filter nothing.
event_filtering:
whitelist:
- Order Completed
- Product AddedPer-source keys
Both keys are objects keyed by the local source type — the tokens listed under Source types. A key naming a source type this destination doesn’t support fails validation.
connection_mode
Type:
object
Description:
Maps each source type you connect to the mode its events reach Firebase in. Firebase accepts only device.
Notes:
- An entry is required for each source type you connect — see Connect a source.
- Any other mode fails validation — for example
cloudforandroid.
connection_mode:
android: device
ios: device
react_native: deviceconsent_management
Type:
object
Description:
Consent provider configuration per source type. The entry shape, accepted providers, and the rules on resolution_strategy and consents are shared across all destination types — see Consent management.
Source types
Firebase accepts events from these source types in the mentioned connection modes:
| Source type | Connection mode |
|---|---|
android | device |
android_kotlin | device |
ios | device |
ios_swift | device |
unity | device |
react_native | device |
flutter | device |
Firebase accepts only mobile SDK sources, and only in device mode — the SDK loads Firebase in the app, and no events pass through RudderStack’s servers. It doesn’t accept web, cordova, or cloud sources. See Add device mode integration.
Connect a source
An event stream connection to this destination is checked against two rules at validate time.
The source’s type must be supported. Firebase accepts the types the mobile SDK sources resolve to. A JavaScript source resolves to web, a Cordova source to cordova, and webhook and server-side SDK sources to cloud — none of which Firebase accepts — and reports, for example:
destination 'firebase-prod' (type 'firebase') does not support source 'my-web-app':
source type 'web' is not among supported source types: android, android_kotlin, ios, ios_swift, unity, react_native, flutterThe destination config must carry a connection_mode entry for that source type. This lives on the destination spec, not on the connection spec. Without it:
destination 'firebase-prod' config has no 'connection_mode' entry for source type 'android'Firebase needs no additional config keys to connect a source of any supported type.
Secrets
Firebase has no secret keys, and no credentials in its config at all. The app authenticates to Firebase with the configuration file it bundles.
Changes by release
No changes since this type became available.
For changes across every destination type, see Destination Type Changes by Release.
See more
- Firebase Destination for adding the Firebase SDK to your app, and the event and property mappings
- Destination Type Reference for Rudder CLI for the rules shared across destination types
- Destination YAML Reference for the spec envelope