DEV Community

Evan Lin
Evan Lin

Posted on • Originally published at evanlin.com on

Cloud Platform: Choosing Between Heroku and Render as an AI (LLM) Engineer

title: [Cloud Platform] AI (LLM) Engineer's Choice of Cloud Platforms: Heroku vs. Render
published: false
date: 2024-01-03 00:00:00 UTC
tags: 
canonical_url: http://www.evanlin.com/heroku-render/
---

![image-20240104115649015](http://www.evanlin.com/images/2022/image-20240104115649015.png)

# Background:

Friends who have been following my blog know that I like to use Heroku to quickly deploy my own cloud services (or LINE Bots). Heroku initially attracted many developers with its ease of use and free plan. However, after November 2022, Heroku started charging, leading many users to look for alternatives. You can check out the following related information:

- [About Switching from Heroku to Render](https://israynotarray.com/other/20221213/3036227586/)

- [Five Platforms to Replace Heroku: Free Testing of .Net Core Text Recognition OCR Web Programs](https://blog.user.today/fly-io-asp-net-core-docker-ocr/)

- [Migrating from Heroku to Fly.io](https://medium.com/codememo/%E7%AD%86%E8%A8%98-%E5%BE%9E-heroku-%E9%81%B7%E7%A7%BB%E8%87%B3-fly-io-5f9f5cdb837b)

Since I have about **50~80** Hobby Projects, I chose to stay with Heroku for now? (It's really tiring to migrate) The monthly fee of five US dollars is also quite reasonable, as it's somewhat unlimited (1000 dyno hours), which is enough for me.

But I heard reminders and encouragement from friends, so I decided to take a serious look and test the results.

# tl;dr: Conclusion First

- Heroku ($5) doesn't have a free tier, but the shared Eco Dyno is actually powerful enough. Render ($7) charges individually for each, which is a bit expensive.
- I will start deploying some projects to Render's $0 plan, the reason will be mentioned later.
- Both are deployed and published, but I will still stay with Heroku ($5) (because it shares 1000 hours)

## Price Comparison (based: 2024/01/02)

## Render's Price and Performance: (free/Starter)

According to [Render vs Heroku by Render](https://docs.render.com/render-vs-heroku-comparison), there are some comparison tables:

![image-20240104095253552](http://www.evanlin.com/images/2022/image-20240104095253552.png)

Seriously looking at [Render's pricing](https://render.com/pricing)

![image-20240104095320382](http://www.evanlin.com/images/2022/image-20240104095320382.png)

- It seems that the Free-tier has 512MB RAM, which is very good (but pay attention to the CPU 0.15)
- But you need to pay attention to the Free Bandwidth of 100GB, which feels like it will be exceeded.

![image-20240104095420088](http://www.evanlin.com/images/2022/image-20240104095420088.png)

- Not to mention the free 90-day PostgresSQL database

![image-20240104095506022](http://www.evanlin.com/images/2022/image-20240104095506022.png)

- Redis with 25MB is also enough, but it will be cut off.

## Heroku's Fees and Performance

- No Free-tier
- Minimum charge Eco $5

According to [Heroku Dyno Types](https://devcenter.heroku.com/articles/dyno-types):

![image-20240104095813909](http://www.evanlin.com/images/2022/image-20240104095813909.png)

- The performance is not much worse than $7 (of course, far more than Render Free-Tier)

![image-20240104095917259](http://www.evanlin.com/images/2022/image-20240104095917259.png)

## Quick Test Results

I used the project https://github.com/kkdai/linebot-gemini-prohttps://github.com/kkdai/linebot-gemini-pro for testing and found:

- The response speed on Heroku ($5) and Render ($0) is not much different. (Golang App)
- But after uploading photos, processing on Render ($0) will crash. Since the memory is 512MB for both, the problem may be with the CPU.

### Cross-testing:

I added another small project: [https://github.com/kkdai/pdf\_online\_editor?tab=readme-ov-file](https://github.com/kkdai/pdf_online_editor?tab=readme-ov-file)

![img](http://www.evanlin.com/images/2022/demo.png)

The test results show that Render ($0) will also crash.

### Testing a 44.8MB PDF file

##### Heroku ($5)

![image-20240104121612188](http://www.evanlin.com/images/2022/image-20240104121612188.png)

##### Render ($0)

Failed after waiting too long….

![image-20240104121857862](http://www.evanlin.com/images/2022/image-20240104121857862.png)

## Testing after payment (\(\))

![image-20240104122958983](http://www.evanlin.com/images/2022/image-20240104122958983.png)

- No response… (!!!)
- Okay! Tragic~~~ When doing RAG, a large amount of CPU is needed. Render ($7) also cannot meet my needs.

#### Render charges per project, Heroku shares 1000 hours

- Opened two projects, each estimated at $7. The total expected charge is $12. This is a bit surprising to me.

![image-20240104123423199](http://www.evanlin.com/images/2022/image-20240104123423199.png) ![image-20240104123424548](http://www.evanlin.com/images/2022/image-20240104123424548.png)

# Conclusion

Although Heroku ($5) is cheaper than Render ($7), considering the following aspects, I might start enabling them simultaneously:

- Render has a free plan, which is more suitable for promotional activities.
- Render ($7) has a DB that can be used, but Heroku ($5) requires extra payment for the database.
- Render ($7) provides more management pages and related functions.

But… because Heroku($5) (CPU) »» Render ($7), and Render ($7) charges per project. If you open too many, you might not be able to handle it at all.

I might need to consider it carefully…

# Please recommend a good cloud service for me

If you have other good recommendations, please leave a message for me. My requirements are as follows:

- Since I have many Hobby Projects (30 ~ 50), I hope to share the cost. (e.g., 1000 hours shared)
- I hope there is a spending limit, so it doesn't accidentally exceed the budget.
- I hope the CPU can be a bit higher, as RAG and LLM require a lot of CPU and RAM.

# References:

- [About Switching from Heroku to Render](https://israynotarray.com/other/20221213/3036227586/)

- [Five Platforms to Replace Heroku: Free Testing of .Net Core Text Recognition OCR Web Programs](https://blog.user.today/fly-io-asp-net-core-docker-ocr/)

- [Migrating from Heroku to Fly.io](https://medium.com/codememo/%E7%AD%86%E8%A8%98-%E5%BE%9E-heroku-%E9%81%B7%E7%A7%BB%E8%87%B3-fly-io-5f9f5cdb837b)

- [Render vs Heroku by Render](https://docs.render.com/render-vs-heroku-comparison)
Enter fullscreen mode Exit fullscreen mode

Top comments (0)