How to connect Firebase to Slack for backend events with no other home
Connect Firebase to Slack for crashes, auth anomalies and Firestore writes that should never happen. Compare Cloud Functions with external automation.
On this page
- Key takeaways
- What we'll cover
- Signals from four different products
- Cloud Functions or external automation
- Building it with CodeWords
- Crash reporting, which needs a release baseline
- Authentication events worth watching
- Firestore writes that should never happen
- Cost alerts, which arrive too late by default
- Staged rollouts, where the alerting has to keep up
- Making it survive
- Limits worth knowing about
- What to set up first
- Frequently asked questions
- Related reading
To connect Firebase to Slack, pick a small number of signals from across Firebase (crashes, authentication patterns, bad Firestore writes and cost spikes) and send them to the channel where the responsible team already works. Firebase's parts do not talk to each other, and none of these events notifies anybody by default.
Key takeaways
- Firebase has no single event stream, so build alerts from a few chosen signals across Crashlytics, Authentication, Firestore and billing.
- Use Cloud Functions for Firestore and Authentication triggers, and external automation for scheduled checks, routing and reporting.
- Alert on crash-free rate and crash velocity for the current release, not on raw crash counts.
- Alert on the rate of change in cost, because Google Cloud budget alerts arrive after the money is spent.
- Segment staged-rollout alerts by version and include the rollout percentage in the message.
What we'll cover
- Signals from four different products
- Cloud Functions or external automation
- Building it with CodeWords
- Crash reporting, which needs a release baseline
- Authentication events worth watching
- Firestore writes that should never happen
- Cost alerts, which arrive too late by default
- Staged rollouts, where the alerting has to keep up
- Making it survive
- Limits worth knowing about
- What to set up first
- Frequently asked questions
Signals from four different products
Useful Firebase alerts draw from Crashlytics, Authentication, Firestore and Realtime Database, and billing. Each product behaves differently, so a good integration picks a few signals instead of forwarding any one product wholesale.
- Crashlytics reports crashes and non-fatal errors, with velocity and affected-user counts. Most mobile teams start here.
- Authentication has sign-up and sign-in events that are available through functions, not as a stream you can subscribe to externally.
- Firestore and Realtime Database produce document and node change events, reachable through triggers.
- Billing and usage live separately in the Google Cloud console and are the most likely to surprise a team.
- Performance monitoring and App Check add their own signals on plans and configurations that include them.
Cloud Functions or external automation
Use Cloud Functions for document and authentication triggers, and external automation for everything else. A thin Cloud Function can forward the event outward, while the logic, formatting and routing live where you can see and maintain them.
- Cloud Functions for document and auth triggers. They fire inside Google's environment with low latency, and no external mechanism subscribes to these triggers directly.
- External automation for scheduled work, for anything crossing into other systems, and for anything you want maintained alongside your other workflows.
- External automation for reporting, which needs no proximity to the data.
- Avoid the trigger loop. A function that writes to the collection it watches is a classic and expensive mistake, and the bill arrives before the realization.
- Watch cold starts and timeouts in functions that do substantial work. They are a common reason a trigger-based notifier disappoints.
Building it with CodeWords
CodeWords connects to 3,000+ integrations (CodeWords integrations directory, 2026), and you make each connection once and reuse it. You describe the outcome and Cody, the automation builder, builds, connects and deploys it.
- Open CodeWords and start a new automation.
- Describe to Cody what should happen in plain language: which signal, what threshold, and who should be told.
- Authorize the connection with a service account scoped to the project, and to your Slack workspace.
- Describe the exceptions: a known crash, a spike caused by a release, an auth pattern from your own testing.
- Test against a non-production project and a test channel before anything reaches the team.
The free plan covers light use. Pro costs $39 per month ($33 per month billed yearly) and Business costs $100 per month (CodeWords pricing page, 2026). Details are on the pricing page.
Crash reporting, which needs a release baseline
Crash alerts need a release baseline: compare the current version against the previous one, not against all history. Crash reporting is the most valuable Firebase signal and the one most often configured badly.
- Compare against the release. A new crash in the current version matters. The same crash that has existed for four releases is a backlog item.
- Use crash-free users, not crash counts. A count rises with adoption, so a new release always looks worse. The rate is what changed.
- Alert on velocity. A crash affecting a rising share of sessions within hours of a release is the one that warrants stopping a rollout.
- Name the version and platform. A crash on one platform at one version is a different conversation from one affecting everybody.
- Distinguish new from regressed. A crash that was fixed and has returned is worse news than a new one, and the two look identical without the history.
- Send it to the mobile team, not a general engineering channel, because acting on it requires the people who ship the app.
Authentication events worth watching
Five authentication events deserve alerts, and each indicates something specific.
- A spike in sign-up rate is either a marketing success or an abuse pattern. Check it either way.
- Repeated failed sign-ins for one account can mean an attack or a locked-out user.
- Sign-ups from an unusual concentration of addresses or domains have the shape of automated account creation.
- Rising account deletions are a product signal that appears in no dashboard by default.
- A failing provider. If federated sign-in through one provider stops working, users cannot get in and nothing reports it. Only a synthetic check (a scripted test sign-in) catches it.
Firestore writes that should never happen
Check Firestore for writes that should never happen by framing the work as data quality, not alerting. This category finds real bugs.
- Documents missing required fields, written by a client version that predates them or by code that skipped validation.
- Values outside plausible ranges, such as a negative balance, a date far in the future, or a count above its bound.
- States that should not persist, such as an order pending for a week.
- Orphaned references left by a deletion that did not clean up.
- Security rules that do not apply to your automation. The Admin SDK bypasses them, so validation that lives only in rules does not constrain what a backend process writes. That is often how bad documents arrive.
Run these checks on a schedule and report the findings. A per-document trigger alert is noise, because the value is in the pattern.
Cost alerts, which arrive too late by default
Google Cloud budget alerts are informational: they stop nothing, and they often arrive after a meaningful amount is spent. Alert on the rate of change in cost instead.
- Reads are usually the cost in Firestore, and the biggest consumer is frequently a query nobody remembers writing.
- Alert on the rate of change. The rate tells you something is wrong, while the threshold tells you it already happened.
- Report by collection and access pattern where you can, so the alert points at the cause.
- Watch after every release. A changed query is the usual cause of a sudden cost increase, and correlating the two is straightforward if someone looks.
Staged rollouts, where the alerting has to keep up
Staged-rollout alerting must segment by version and expect small numbers early. Mobile releases go out gradually, and an alert that ignores this reports the wrong thing.
- Segment by version. A crash rate across all users is dominated by the versions most people use, which hides a serious problem in the small share on the new version.
- Expect small numbers early. A rollout at one per cent produces few sessions, so rates are volatile. A minimum-volume threshold prevents alarms at noise.
- Compare the new version with the previous one at the same point in its rollout, not against its eventual steady state.
- Watch the first few hours closely, then relax. The halt-or-continue decision is made early, and alerting at the same sensitivity afterwards is noise.
- Include the rollout percentage in the message. A crash rate means something different at one per cent than at fifty.
- Say what to do. "Consider halting the rollout" is an instruction. "Crash rate elevated" leaves someone to work out whether it is their decision.
Making it survive
Make the alerting survive by keying events, avoiding dependence on the failing service and deduplicating alerts.
- Make it idempotent, keyed on the event, because function invocations can repeat.
- Do not alert from inside the thing you monitor. A notifier that depends on the failing service stays silent exactly when you need it.
- Deduplicate crash alerts so one issue produces one message with updates, not a message per occurrence.
- Handle the missing field explicitly instead of treating absent as zero.
- Report the outcome: alerts sent, checks run, and anything suppressed as known.
Limits worth knowing about
Five limits shape a Firebase to Slack integration.
- Cloud Functions have cold starts and timeouts, which affect anything doing substantial work in a trigger.
- Firestore charges per document read, so a scheduled scan of a whole collection is expensive and gets more so as the collection grows.
- Authentication events are available through functions, not as an external subscription, so something must run inside the project.
- Security rules do not constrain the Admin SDK. Remember this when deciding what your automation may do.
- Slack rate limits apply, which matters during a crash spike when volume is highest.
What to set up first
Set up crash-velocity alerting on the current release first. It should flag a crash affecting a rising share of sessions in the hours after a rollout, sent to the mobile team with the version and platform named. This signal has the shortest useful window, because it supports the decision to halt a staged rollout.
Two habits make the difference. Alert on crash-free rate, not crash count, because counts rise with adoption. And distinguish a returning crash from a new one, because a regression is a different conversation.
Frequently asked questions
Cloud Functions or external automation?
Use Cloud Functions for Firestore and authentication triggers, since nothing external can subscribe to them. Use external automation for scheduled checks, reporting and anything crossing into other systems. A thin function that forwards events outward gives you both.
What crash metric should alerts use?
Use crash-free users or sessions, not crash counts. Counts rise with adoption, so every release looks worse than the last. The rate is what changed, and its velocity within hours of a rollout supports a halt-or-continue decision.
Why is our Firebase bill rising?
The usual cause is Firestore reads: a query returning far more documents than it uses, or a scheduled job scanning a whole collection. Alert on the rate of change in cost, because a budget alert arrives after the money is spent.
Can I alert on bad data in Firestore?
Yes, with a scheduled check, not a per-write trigger. Report documents missing required fields, values outside plausible ranges and states that should not persist. Security rules do not constrain the Admin SDK, which is often how those documents arrived.
What authentication signals matter?
Watch for sign-up spikes, repeated failures on one account, concentrations suggesting automated account creation, and a federated provider that has stopped working. The last one is invisible without a synthetic check and stops users signing in entirely.
Where should crash alerts go?
Send crash alerts to the mobile team's channel, not general engineering. Acting on a crash requires the people who ship the app, and an alert in a channel where nobody can act on it gets muted.
How do I avoid an expensive trigger loop?
Never let a function write to the collection it watches. This is the classic Firebase mistake. It compounds silently, and the bill is usually the first sign. Write results to a separate collection or send them outward instead.
How should alerting handle a staged rollout?
Segment by version and require a minimum session volume so early small numbers do not cause alarm. Compare the new version with the previous one at the same rollout stage, and include the rollout percentage in the message. A blended rate across all versions hides the problem.
What should a crash alert say?
State the version, platform, rollout percentage, whether the crash is new or returning, and the decision it supports. "Consider halting the rollout" is actionable. "Crash rate elevated" leaves the recipient working out whether the call is theirs.