What's your preferred hosting solution for SaaS backend infrastructure?

Hey everyone! I’m trying to figure out the best way to set up the backend for my microSaaS project. Since it’s not gonna be super busy all the time, I’m wondering what you all think is the smartest choice.

Are you Team Serverless with things like cloud functions, or do you prefer going old school with virtual machines? I’ve heard good things about both, but I’m not sure which way to go.

Also, I’d love to hear about specific services you’ve had good experiences with. Any recommendations for a newbie? Thanks in advance for sharing your thoughts!

// Example serverless function
exports.handleRequest = async (event, context) => {
  const data = JSON.parse(event.body);
  const result = await processData(data);
  return {
    statusCode: 200,
    body: JSON.stringify(result)
  };
};

// Example VM setup
const express = require('express');
const app = express();

app.post('/api/data', async (req, res) => {
  const result = await processData(req.body);
  res.json(result);
});

app.listen(3000, () => console.log('Server running'));

i’ve had good luck with digitalocean droplets for my saas stuff. cheap, easy to set up, and they got good docs. plus you can scale up when you need to. just make sure you set up backups, learned that the hard way lol. might not be as fancy as serverless but it gets the job done

Hey there! have u considered heroku? It’s super user-friendly for beginners and scales pretty well. I’m curious tho - what kinda traffic are you expecting? And how comfy are u with server management? Those factors could really impact your choice. What’s your main priority: ease of use or fine-grained control?

For SaaS backend infrastructure, I’ve found AWS Elastic Beanstalk to be an excellent middle ground. It offers the ease of serverless deployment while giving you more control over your environment. You can start small and scale as needed, which is perfect for microSaaS projects.

In my experience, Elastic Beanstalk handles a lot of the heavy lifting in terms of provisioning, load balancing, and auto-scaling. This lets you focus on your application code rather than infrastructure management. It’s also quite cost-effective for projects with variable traffic.

One key advantage is the ability to easily switch between different instance types as your needs evolve. This flexibility has been crucial for several projects I’ve worked on, allowing for smooth transitions as user bases grew.