I am planning to build an app that work on both android and ios. The app requires to link with a server database and may use some paid APIs. My plan is to make the app initially free for its users. I wish to know what are the costs that may come in the first 1-2 years for running the app.
After initial setup the costs would be hosting ( AWS/Heroku/Firebase) . For an app with less than 10K users you might need to budget $500 -$1000 an year. There might be 2-3 OS updates or API updates requiring some development cost.
As with most things, the real answer is: It depends.
It depends on how much work you need to do on the back end, how much storage you need per user, how many support feature you want to get, etc. etc.
Also you will need some sort of solution that you can scale with. So you can keep your costs down when you're starting off, and have the server resources you need once you get more people using your app.
Depending on the nature of your app and what you actually need your back end for, all of this could range from roughly $40/mo up to $4000/mo.
You can check out the AWS pricing calculator to get a sense of what all these services are and estimate a total cost.
Free apps primarily have costs related to hosting and yes Amazon Web Services would be a good place to get the costs you would expect. This is because free app users have limited expectations and rarely ask for anything except 'reduce those ads'. On the other hand the real costs for a commercial app, if it is successful is in terms of customer support and customization. This is because once your customers are paying for it, they will expect service. To estimate these costs you will have to look into the kind of support the customers would desire and budget for it. If you could share more specifics about the app you are building we could help you estimate this better.