On firebase hackers plan we get 100MB data storage and 1GB hosting storage. if i'm not mistaken, 100MB is for database data and 1GB is for files storage. I want to create an app that allow user to upload image. I notice most people suggest to use base64 encode for image handling, however i'm worry about the file size will hit the limit of query item size (i'm meant item size limit which similar to "16MB limit of mongodb or 64KB of dynamodb" vs total number of photos) even it is practically not possible to hit the query item size, i worry the query will be slow with all those base64 encode data. Just wondering, could i use the hosting storage to store user images that send from their app?
Asked
Active
Viewed 2,038 times
2
-
possible duplicate of [How can I view and store images in firebase?](http://stackoverflow.com/questions/13955813/how-can-i-view-and-store-images-in-firebase) – Kato Jul 02 '14 at 05:34
-
On "How can I view..", it is stated to use base64 encode. I'm asking about storing the image as a file instead of data in database. – user3478578 Jul 02 '14 at 05:37
-
Much like SQL, a "file" is a meaningless concept in JSON. It's just a blob of binary data. Either encode it and store in JSON, or store a URL linking to the binary and put that on S3 or another service. – Kato Jul 02 '14 at 16:08
-
Yeah Kato, thats what i wanted to do. I wanted to have the url linking to the file. what i'm asking is that the hosting storage mentioned meant for storing the image files or can i use it to store user images? Firebase plan mentioned about data storage and hosting storage, thats why im not sure. if the hosting storage can be use to store user images and data storage for database, then it will be good. – user3478578 Jul 03 '14 at 03:09
-
**Update (20160519)**: *Firebase just released a new feature called [Firebase Storage](https://firebase.google.com/docs/storage/). This allows you to upload images and other non-JSON data to a dedicated storage service. We highly recommend that you use this for storing images, instead of storing them as base64 encoded data in the JSON database.* – Frank van Puffelen May 20 '16 at 04:23