Firebase vs. Supabase for Turn-Based 2D Multiplayer Game or Any Better Option?

I’m working on a 2D multiplayer game with a turn-based mechanic and currently using Firebase (still testing, nothing is done.), but it is the closest option to what I need. I want all game logic to be hosted in the cloud, allowing users to call methods from the server, which will validate these calls. For example, if a user sends a request to roll a die, the server will check if the user is in the game, if it’s their turn, and so on, to prevent cheating.

Players will also subscribe to the necessary paths in the real-time database, enabling real-time communication. When a player sends a request and it gets approved, a cloud function updates the value in the database, and this change triggers an event method in Unity that notifies all players of the update (e.g., the die is rolled and the number is shown).

The logic is now: Player > Firebase Cloud Function > Firebase Realtime Database > Back to Players.
I’m looking for something like that.

Given this approach, the only options I’ve found are Firebase and Supabase. Is there any other way?

I’m looking for similar server offerings that are more cost-effective, as Firebase seems quite expensive for a larger number of players. There is a strong possibility that the game will initially have a significant player base, especially since a few YouTubers with millions of views will be showcasing and playing it. I would appreciate your thoughts and perspectives if you have worked on similar games and security models. Which servers did you use and why?

The game is very detailed, and there will be many function calls throughout the gameplay. Imagine a game like Monopoly or Tapestry, at that level of detail.

The game should be accessible and secure for all players, so I prefer not to use P2P connections due to security concerns regarding hacking.

We will secure the game in various ways to cover costs, considering different options that are not important right now (for this post), but we are looking for a better way to avoid high expenses, which would be great. Do you have any experience with Firebase or Supabase? Or do you have a better solution or hosting option, and why? This information is very important to us.

Make a financial calculation / estimation. Just because you pay a lot more for a large user base doesn’t mean it isn’t cost-effective. You are also making more money from more players, right?

If your game scales in a way where it gets less and less cost effective for you to host large numbers of players, then the game is destined to fail. If you can be in a situation where, if the game grows in popularity, you actually risk losing money then clearly something is wrong.

And with the estimation, you may end up noticing that yeah, you’ll be paying $1,000 more for this service over the other but that needn’t guide your decision if we’re talking about making either $49,000 or $50,000 in a given month. Perhaps those $1,000 are well spent due to service reliability, scalability, or other factors.

In any case, Unity Cloud Code and Cloud Save are also options. You can try my Unity Gaming Services Cost Calculator to get a grip on those numbers.

1 Like

Your response is honestly the best I’ve received so far, and I’ve asked the same question on various platforms. When you put it this way, everything becomes clearer. Thank you so much for the links; I’ll definitely go over all the costs and potential profits with my team. This really means a lot to me because my thoughts are scattered in a hundred different directions, and I’m not sure where to start—whether to tackle hosting, costs, or try to plan everything out better, which only raises more questions I didn’t have answers to. Thanks again!

1 Like