Firebase can be both used from the client (eg: Web, mobile apps), but also from the backend (eg: NodeJS). You may query directly Firebase over the network, right from your backend, but you should avoid doing this because it is really slow at scale .
Read moreCan I use Firebase for authentication only?
Yes, you can use Firebase for auth only and link it to your own database .
Read moreIs it good to use firebase authentication?
Firebase Authentication aims to make building secure authentication systems easy, while improving the sign-in and onboarding experience for end users . It provides an end-to-end identity solution, supporting email and password accounts, phone auth, and Google, Twitter, Facebook, and GitHub login, and more.
Read more