What is Firebase Hosting?
Firebase Hosting is a fully-managed hosting service for static and dynamic content as well as microservices. The service is backed by SSD storage and a global CDN (content delivery network). Zero-configuration SSL is built into Firebase Hosting, so content is always delivered securely.
What can you host?
Build then host your microservices, API, and forms
Pair Firebase Hosting with Cloud Functions to build microservices using the Express.js framework. This pairing allows you to host your microservices and APIs on Firebase. In addition, you can use a deep integration with Cloud Firestore to build very powerful forms and web apps which can update data in real time.
Host your single-page web apps, marketing websites, and static and dynamic assets
Add a custom domain (or a subdomain)
With Firebase Hosting, you're automatically given a Firebase sub-domain, but
you can choose to serve your content on a
custom domain (like
myrealtimeapp.example.com). Firebase Hosting
provisions an SSL certificate for each of your domains and serves your content
over a global CDN.
Keep all your sites in one place
Firebase Hosting supports multiple sites in a single Firebase project. Each site hosts its own collection of content, has its own hosting configuration, and can have one or more associated domains. Since the sites are all in the same Firebase project, all the sites can access the other Firebase resources of the project.
You can use multiple sites in a Firebase project to keep related sites together (for example your single-page app, blog, and marketing website).
Automate continuous deployment with Cloud Build
Firebase Hosting partnered with Cloud Build offers a DevOps-ready solution for automating a continuous deployment workflow for your static and dynamic content as well as for your microservices.
After you configure these tools, you can deploy your web app to Firebase Hosting by simply checking in your code to your git repository.
Restrict access and counter a DDoS attack for your web apps
Using the power of Express.js middleware, you can build custom logic into serving your microservices, APIs, and other HTTP endpoints. For example, with just a few lines of code, you can integrate popular Node.js middleware offerings to build additional security layers, like access management by IP or protection from denial-of-service (DDoS) attacks.
Error pages — Return a neatly fully customized 404 page from your web app.
Rewrites — Customize which endpoints serve what traffic, and even display the same content from multiple URLs.
Headers — Want to access cookies? Use custom headers!
Caching and CDN behavior — Control how your web app is cached across the CDN through custom headers.
Deploy to Firebase from various web-based IDEs
These IDEs automatically detect when you're creating a Firebase app and allow you to deploy to Firebase Hosting with the click of a button, without ever leaving the IDE!
Build deep integrations with other Firebase services
Firebase Hosting works out-of-the-box with Firebase services, including Cloud Functions, Authentication, Realtime Database, Cloud Firestore, and Cloud Messaging. You can build powerful microservices and web apps using these complementary Firebase services.
Try out our FriendlyChat web codelab to learn how Hosting pairs with these Firebase services.
Create a custom deployment workflow using REST API and our Node.js modules
We also have a Node.js module which you can import into your Node.js apps to build advanced functionality.