Installation & Setup for REST API Stay organized with collections Save and categorize content based on your preferences.
TheFirebase Realtime Database is a cloud-hosted database. Data is stored asJSON and synchronized in realtime to every connected client. When you buildcross-platform apps with our Android, Apple platforms, and JavaScript SDKs,all of your clients share oneRealtime Database instance and automatically receiveupdates with the newest data.
We can use anyFirebase Realtime Database URL as a REST endpoint. All we needto do is append.json to the end of the URL and send a request fromour favorite HTTPS client.
Create an Account
First sign up for an account at no cost in theFirebase console. A newFirebase app will be created for you with a unique URL ending infirebaseio.com. You'll use this URL to authenticate your users andto store and sync data to the app's database.
Within theFirebase console you can create, manage and delete Firebaseapps. Clicking on a specific Firebase app lets you view and modify your app'sdatabase in real time. In your app dashboard, you can also setFirebase Realtime Database Security Rules, manage yourapp's authentication, deploys, and view analytics.
Create a Database
Navigate to theRealtime Database section of theFirebase console.You'll be prompted to select an existing Firebase project.Follow the database creation workflow.
Select a starting mode for yourFirebase Security Rules:
- Test mode
Good for getting started with the mobile and web client libraries,but allows anyone to read and overwrite your data. After testing,makesure to review theUnderstand Firebase Realtime Database Rulessection.
- Note: If you create a database in Test mode and make no changes to thedefault world-readable and world-writeableSecurity Rules within a trialperiod, you will be alerted by email, then your database rules willdeny all requests. Note the expiration date during theFirebase consolesetup flow.
To get started with the web, Apple, or Android SDK, select testmode.
- Locked mode
Denies all reads and writes from mobile and web clients.Your authenticated application servers can still access your database.
Choose a location for the database.
Depending on thelocation of the database, theURL for the new database will be in one of the following forms:
(fordatabases inDATABASE_NAME.firebaseio.comus-central1) (for databases in all other locations)DATABASE_NAME.REGION.firebasedatabase.app
ClickDone.
When you enableRealtime Database, it also enables the API in theCloud API Manager.
Choose a Helper Library
You can read and write data through the REST API directly from the command line.In this guide we'll usecURLfor all of our examples. We also have several third-party helper libraries forinteracting with the REST API from your favorite language. You can use one ofthe following helper libraries or create your own:
| Language | Libraries |
|---|---|
| Clojure | taika byCloudfuji |
| Dart | IO Client in the officialfirebase-dart library |
| Go | Firego bySteven Berlanga andTim Gossett Go Firebase by Cosmin Nicolaescu and Justin Tulloss |
| Java | firebase4j byBrandon Gresham |
| Perl | Firebase-Perl by Kiran Kumar and JT Smith |
| PHP | firebase-php bykreait firebase-php byTamas Kalman |
| Python | Pyrebase byJames Childs-Maidment python-firebase byÖzgür Vatansever python-firebase byMichael Huynh |
| Ruby | firebase-ruby byOscar Del Ben BigBertha byFernand Galiana rest-firebase byCodementor |
Next Steps
- Learn how tostructure data forRealtime Database.
- Save data.
- Retrieve data.
- View your database in the Firebase console.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-02-18 UTC.