Reputation: 851
I watched a codeschool tutorial on Node.js and they imitated a chat server using Socket.IO in their tutorial.
I am also under the impression that Firebase does the same thing.
What is the difference between the two, if there are any?
Upvotes: 45
Views: 35769
Reputation: 179
There are many, many differences. For example:
SDKs
Firebase has 9 SDKs, including JavaScript, Android, Unity. Socket just 1 official client library (JavaScript) for browsers.
Realtime Features Firebase has pub/sub messaging, connection state recovery, presence, native push notifications, webhooks. Socket.io doesn't have any of those.
Documentation
Both have pretty good documentation with Getting Started Guides, Information Architecture and Developer Journey, API reference.
Those are just some examples, but here is an in-depth comparison between Firebase and Socket.io
Upvotes: 0
Reputation: 8635
There actually is the difference.
Socket.io is a javascript library to manage sockets. In a web-chat example, you create sockets:
That is, you control all the end-points, and use socket.io as a tool to communicate between your end-points.
In contrast, using firebase you only focus around 1 (client to server)
Pros and Cons of using service versus own infrastructure is a different subject, and heavily opinionated.
Upvotes: 52