When comparing Sails.js vs Google Firebase, the Slant community recommends Sails.js for most people. In the question“What are the best Meteor alternatives for realtime JS apps?” Sails.js is ranked 1st while Google Firebase is ranked 7th. The most important reason people chose Sails.js is:
Sails.js is built with a focus on building real time communication apps such as chat or multiplayer games, so naturally it has Socket.io extremely well supported.
Specs
Ranked in these QuestionsQuestion Ranking
Pros
Pro Transparent support for Socket.io
Sails.js is built with a focus on building real time communication apps such as chat or multiplayer games, so naturally it has Socket.io extremely well supported.
Pro MVC architecture
This could be a huge plus, if you prefer to build your apps using the Model View Controller architecture. Using Sails.js you'll find the task of separating the business logic from the user interface and keeping the interactions between them in a separate layer, extremely easy.
Pro JSON API generated for free
Exposes public JSON API for free. No additional routing to be defined. Makes it pretty easy to access data from anywhere.
Pro ORM that can be plugged into any database, or even custom web service
Sails.js uses Waterline ORM at its backend which means you can store your data in any datastore that you like; all you have to do is make a change to the Waterline adapter, this will allow you to store your data in MySQL/Redis or any other kind of database.
Pro So easy to deploy and lift
Pro Great documentation and structure
Clear documentation and easy to understand. The file structure gives you a way to understand where you can start to develop when you encounter a new Sails project
Pro Flexible Pricing
The Blaze Plan is a pay-as-you-go plan, which is, you pay for what you use, without overhead or upfront costs.
Pro Straightforward hosting
Powered by Google's Cloud Platform, Firebase allows you to deploy static web pages or web applications with a nifty Node.js-based CLI Tool.
Pro Super fast CDN
All static website content is hosted on the Fastly CDN making your website really fast.
Pro More than just hosting web applications
In the core of Firebase allows you to do testing for Android apps, Analytics, Real-time Database, and many more. It's centered mostly for progressive web applications and mobile applications with real-time connectivity to your service.
Pro Almost free if you add Cloudflare in front (no bandwidth costs) and cache effectively
The built-in CDN is great too, but if you're concerned about bandwidth costs, using it with Cloudflare is an excellent option option.
Cons
Con Poor ORM
The built-in Waterline is not well designed and is not suitable for production environments. Populating more than 1 level deep is a nightmare, there is no transaction support, new features/bug fixes are not implemented anywhere near a timely manner (the most requested feature 'deep populate' has been lingering in their github issues list for over a year and a half now).
Con Google blocks Access
Some Google services, software and cloud systems, are not available to certain countries. blocked access by google following USA Policies.
Con Linked to Google Cloud Platform
If you don't have a Google Account, you won't be able to access Google cloud services, including this one.