0
votes

Firestore if I read a collection and the collection contains 100 documents then is firebase calculate it as 100 read operation or 1 read operation?

If my 1 document contains another 2 collections and each sub collection contains 10 docs then How much will be the total read count in this case? if it counts subcollection and it doc separately then Firestore is very very high pricing

1

1 Answers

3
votes

If you read all documents from a collection that contains 100 documents, then you're reading 100 documents. So you'll be charged for 100 document reads.

If you're reading documents from subcollections, then there too: you'll be charged for each document you read.

If you're struggling to find a data model that strikes a balance between a flexible structure and limiting the number of reads you need, I recommend watching the Getting to know Cloud Firestore video series, specifically these episodes: