When designing and building applications, often we find ourselves needing various third-party services, such as databases, push notifications, hosting, authentication, and many other complex features. Firebase, built by Google, is an all-in-one application development platform that provides all this functionality and more, giving us an easy-to-use platform to develop and scale our applications.

To download the source code for this article, you can visit our GitHub repository.

Let’s start by understanding some of the features Firebase provides.

What is Firebase?

Firebase is a service offered by Google for developing and scaling mobile, web, and desktop applications. It originally launched in 2011, with a single service, the Realtime Database, which as the name suggests, is a real-time, NoSQL database that allows storing and syncing of data between users.

Now, Firebase is much more than just a NoSQL database. Let’s look at some of the features it offers:

  • Authentication: an end-to-end authentication system, allowing users to authenticate to our applications using simple email and password accounts, through to social logins with Google, Facebook, GitHub, and many more.
  • Cloud messaging: Firebase focuses a lot on the mobile application market, so we need to send and receive notifications to Android and iOS devices frequently, which is covered by the cloud messaging functionality.
  • Hosting: we need somewhere to host our applications, which is where the Firebase hosting features come into play. It allows for simple previewing, deployment, and rollback of our applications.
  • Cloud storage: More often than not, we want to store files for our users, such as photos and videos. Firebase provides a fast and reliable cloud storage platform for handling these scenarios.

Create Firebase Project

There are various client libraries for different programming languages, including .NET, that allow us to interact and develop applications with Firebase. There is a great list of the available libraries on GitHub, a few of which we’ll explore in this article. To start, let’s create a new web application using the Visual Studio Project Wizard or the dotnet new webapp command.

To kick things off, we need a Firebase project. A Firebase project is a top-level entity that we use to manage the various services on offer. We create Firebase projects from the Firebase console, so let’s start with that.

With our project created, let’s retrieve the Project ID as we’ll need this later on for interacting with various services.

To retrieve this ID, from the project overview, navigate to Project settings: