Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

189
Views
I get a missing permissions error in firebase even though I allow it to read

I am working on a react firebase project.

the error I am getting is

"FirebaseError: Missing or insufficient permissions."

Here is my code to get the data

  const data = await getDocs(
    query(collectionGroup(db, "posts"), orderBy("upvote", "desc"), limit(5)));

Here is my firebase security rules

rules_version = '2';
service cloud.firestore {
  match /databases/{database}/documents {
    match /posts/{docId}{
        allow read;
        allow update: if request.auth.uid != null;
    }
  }
}

I have no idea what is going on I allow read in firebase rules but when I go and get the data it does not work

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

You should check if in the Database under the rules if read: true and write: true if not make those true.

So go to DataBase-> Rules make

  1. Read:true
  2. Write:true

But for production databases allow only for authenticated users

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!