How to estimate backend costs

Hi,

I m working for a business plan for a new app business and I’m struggling with calculation the estimated infrastructure costs.

I don’t need totally exact numbers but a rough estimate.
If you have done something similar, how did you approach this?
Can you share your cost/user and monthly users from your project?

Depends on the size of you project, how big is your project?

You can go from complete free Oracle “free or life” to $1000’s

1 Like

Currently hard to estimate. That’s why I asked for experiences from other users

To echo the last comment - I think this depends on complexity.

As well as my current side project where I use AWS Amplify, I worked at a startup where we deployed Firebase.

At the startup we had a lot of complex data processing (FIT files from exercise & generated run coaching). Despite having a small user base, we racked up significant costs. We tried to calculate what our BE costs would be and dare I say it we underestimated.

Now, my side project - whilst complicated - is significantly less heavy on the backend. I’ve still got a limited number of users but my costs are almost non-existent.

Part of this could be down to the differences in platform - Amplify comes with a GraphQL API so even though the data isn’t stored in a relational database (it’s dynamoDB under the hood) you can easily make related data requests. But I think the complexity is the main difference.

So now for the advice bit: there’s nothing to stop you doing a prolonged closed testing phase, watching the payments you’re making and monitoring usage. That way you can extrapolate from user base/MAU and monthly costs to calculate things like profitability and your runway.

The problem is that while you work on a business plan you are far from being able to do any testing.
From a longer discussion on Bluesky today it seems that especially when you self host the costs per user get pretty small.
Interesting to hear how big the difference was when the app needed to do a lot of calculations.

Why do you build a test case on the free tier and stress test it.

I have a free tier that have 10 clients on it and 30 devices doing API calls (writing data to InfluxDB) and 50 API calls to another server and writing data to InfluxDB.

In 3 years have not had any load issue.

You can get far on the free tiers.

1 Like

@Johan why did you choose oracle which is not the most popular cloud?

AWS you pay afrer a year and they are expensive.

1 Like

Oracle needs to be aggressive as the last market contender
Their free tier is generous… but can be reclaimed quickly under charge…

2 Likes

How long is a string? :sweat_smile: The cost will depend on many factors. How many users are you expecting? Will you need to just fetch updates from the server occasionally or do you need frequent real-time communication? How much data need to be passed in your calls?

As a rule of thumb, the server instances themselves are usually quite inexpensive. We did some experiments with Serverpod and we can easily fit 1,000 simultaneous real-time users on one single, small virtual server (~$10/mo). Often, the most expensive part is the database, because you probably want some sort of backups and redundancy. This may also be a challenge to do well if you’re self hosting. It’s often possible to reduce the cost by caching results, and minimize the database usage.

If you are expecting a lot of users, you will also need to think about load balancing and how you scale your server cluster. Which adds some additional costs.

I can probably give you a bit better advice if I have some more information about what you’re building. :slightly_smiling_face:

6 Likes

Great reply! Hits the nail on the head!