What's the Best Way to Deploy My Laravel App Without Breaking the Bank?
Asked by
tabulate
I've built several apps over the past couple of years, but whenever I reach the deployment stage, I often hesitate and sometimes give up, mainly due to concerns about cost and whether the project is truly worthwhile. This time, however, I have a great project that I want to deploy so I can test it further, even if it costs me up to $50 for a month of hosting. I am looking for advice on the best host to choose, especially since I am feeling overwhelmed by the many options available, particularly with Ubuntu VPS providers. I've mostly used the free versions of platforms like Vercel and Railway, but I'm looking for a more centralized and budget-friendly solution. Here's my project stack:
- **Framework:** Laravel 11 (PHP app)
- **Frontend:** Inertia.js + Vue 3 + Vite build output
- **Web server:** Nginx (or Apache), PHP-FPM
- **Database:** MySQL or PostgreSQL (still deciding)
- **Cache/Rea-time state:** Redis (needed)
- **Real-time/WebSockets:** Laravel Reverb (long-running process)
- **Background jobs:** Laravel Queue Worker (`php artisan queue:work`)
- **Scheduled tasks:** Cron running Laravel scheduler each minute (`php artisan schedule:run`)
- **SSL:** HTTPS certificate (essential for production)
- **Deployment needs:** Running persistent processes (`systemd/supervisor`) + SSH access. Any recommendations on where to host this and how to manage costs?
Answers
It sounds like you want an easy deployment without getting deep into DevOps, which is completely understandable. I'd recommend:
1. For the least setup hassle, try Cloudways. You basically pick a server, click a few buttons, and they handle setting up everything you needโit's ever so slightly pricier but worth it for the ease.
2. If you're looking for a balance between cost and ease, consider a cheap VPS and use Laravel Forge or Ploi to manage the setup.
3. For the most budget-friendly option but with more manual work, a raw VPS from providers like DigitalOcean or Hetzner is the way to go. Just know you might hit a steep learning curve. But don't worry, once you've deployed one app, it'll click for you!
Reply to this answer
I'd suggest going with Digital Ocean for a VPS with 4 to 8 GB of RAM; it's quite affordable and works really well with Laravel. Try installing Coolify on it to make running all your applications a breeze. Don't be afraid to make mistakes during the setup processโit's how you'll learn!
Reply to this answer
Your stack is solid for a small VPSโsomething with 2 vCPUs and 4-8 GB RAM on Ubuntu should handle Laravel, Redis, queues, and websockets efficiently. Consider Kainode, which offers daily billing on their VPS/VDS allowing you to test deployment with minimal risk. They also have handy live support if you need help along the way!
Reply to this answer
Having worked with Laravel extensively, Iโd suggest you start with Laravel Forge connected to your AWS account. It simplifies everything related to deployment. If you plan for growth down the line, start on Forge; later, you could transition to Laravel Envoyer for managing multiple servers without much hassle.
Reply to this answer
Honestly, it doesnโt matter too much which host you chooseโjust pick one and keep moving forward. Iโve had good experiences with AWS!
open-source-notes: Totally agree! AWS has a simple service called Amplify that can make things super straightforward.
Reply to this answer
Add your answer
Answers are reviewed before publication.
Puzzler: Don't forget that Laravel Cloud might work well for you too if you're looking for a fully managed service that now supports websockets.