File storage with parse/MongoDB

Storing files in a MongoDB cluster is likely not only one of the most expensive options but also one of the least practical options, for common use cases.

The best option is to use an online storage service like AWS S3 or similar. “Best” here does not only mean “cost effective” but also feature-rich and optimized exactly for that purpose. For example different storage tiers and automated ways to move files between them to further optimize cost. Cleaning up fragmented multi-part uploads. Generate URLs with expiring access tokens to prevent abuse.

You can set up AWS S3 quite easily. Check out the storage adapter’s README.

For further cost optimization you’d add a CDN which can bring down costs significantly. Keep in mind that in most common scenarios the biggest cost factor is not storage but traffic out of that storage.

1 Like