Rocket vs Actix Web vs others

Hi all

I am new in Rust world and would like to develop rest services. I need a framework but do not know, which web framework should I take. Looking at the Github repo Rocket and Actix Web have the most stars.

Which framework do you recommend me to use?

Thanks

As far as I know rocket should be rather good. It currently requires the nightly compiler, but I heard on the podcast "Rustacean Station" that it should be compatible with stable starting with the next release.

I am no hard core web developer, I am new to Rust, I wanted to put up a web server for a simple, low load site, mostly static pages and a simple REST API. Data coming from our CockroachDB database.

As such my comments about Rust web servers is not worth much.

However I'm using Rocket. Selected because I was not aware of any other options but mostly after being fired up by Sergio Benitez presenation on YouTube: "Rocket: Securing the Web at Compile-time": https://www.youtube.com/watch?v=p792bWipnz8. It was also confidence inspiring to hear that people like NPM, System76 and Mozilla are using Rocket in production.

It worked out very well. Simple to use for this Rust newbie. Running reliably for months now.

2 Likes

You won't get disappointed with either rocket or actix-web. I am currently using actix-web but have done some work on rocket, too. I think rocket has the better onboarding, thus may be more helpful for Rust beginners. I am using actix-web because of specific features i need and the increased performance demands i have. But i was absolutely happy with rocket in my previous projects.

1 Like