Hide sensitive data on Firebase Hosting

321 Views Asked by At

I am using my react, redux, firebase, Firestore, auth project and uploaded my project on free google Firebase Hosting.

I am newbie when I goto inspect and check the console and other code. my code and information still visible to general public like user email and first and last name. I was thinking npm run build hides everything automatically.

please help me how to hide sensitive data on free Firebase Hosting.

much appreciated.

1

There are 1 best solutions below

1
Doug Stevenson On

Everything you deploy to Firebase Hosting is public. There is no way to change this behavior.

If you are worried about your Firebase configuration, that must be public, and it is safe as long as you have security rules correctly in place. See also: Is it safe to expose Firebase apiKey to the public?