This page describes how to build secure apps on the Firebase platform.
Firebase provides a full set of tools for managing the security of your app. These tools make it easy to authenticate your users, enforce user permissions, and validate inputs.
- Data validation
- Learning More
Securing Your Data
Enforce how your data is structured and when read/write permissions are given.
- types of rules
- predefined variables
- existing vs. new data
- referencing other paths
- security and Firebase rules cascade
- rules are not filters
- using $ variables
User Based Security
Create a complete solution for securing your data with user authentication.
This document explores the predefined
auth variable to create a complete solution for securing our data.
- the auth variable
- using custom tokens
Indexing Your Data
Improve query performance by specifying what keys you will be indexing on.
Firebase allows you to do ad-hoc queries on your data using an arbitrary child key. If you know in advance what your indexes will be, you can define them via the
.indexOn rule in your Security and Firebase Rules to improve query performance.
- defining data indexes