If you were a startup trying to get an MVP out the door in 2010, admittedly you probably used or considered Ruby on Rails. In 2015 you are probably more than likely going to opt for Node.js instead. But why?
Once upon a time it seemed as if Ruby on Rails was destined for global dominance. Twitter was originally built on top of it before moving for scalability and performance reasons, but many companies still use Ruby on Rails.
Some notable companies still sporting the faded Rails band t-shirt include; Github, Shopify, Twitch.tv, Imgur, Airbnb and the list goes on.
Rails is definitely not dead, however you can’t deny the trends for Rails usage are going down, not up. It is no longer considered to be the only darling of the startup world like it once was.
So.. what happened?
While the appeal of Ruby on Rails was very much its plethora of generators and other CLI goodies that made it easy to scaffold an application in a matter of minutes: Node.js happened.
The appeal of Node.js was the fact that developers could apply their existing skillset and Javascript knowledge to the server side. The issue with Rails is even though you could use it with next to no knowledge of Ruby, to truly harness its power, you had to learn Ruby.
Then there is the history of well-documented performance problems plaguing the framework, more publicly Twitter’’s move away from the framework.
Ruby on Rails was never marketed as a performance-first framework, it was marketed as a framework you chose when you wanted to get shit done and as quickly as possible. There is no denying that Rails delivered on that promise.
As you can see comparing Google Trends data for Ruby on Rails and Node.js paints a very clear picture:
The appeal of Rails was not only attributed to the fact there was nothing really like it at the time (unless you consider Django and Django). PHP was the dominant language when Rails made its debut and people jumped ship because the PHP hate-train was speeding down the tracks.
Of course, there were other reasons that can be attributed to the early success of Rails. The inbuilt ORM, the scaffolding functionality and ability to generate an entire application using a few simple CLI commands appealed to many of us as developers.
Ruby on Rails isn’t dead
While RoR is alive and well, it just isn’t the flavour of the week like it used to be. It seems Node.js has won out, but that isn’t to say that Node itself won’t be replaced by something in the future.
There is still a community behind Ruby on Rails, albeit not as vocal or big as the Node.js community. It is far from dead, but we have to wonder if there will come a day when Rails falls behind even further.
The stats
It isn’t exactly a fair comparison to compare NPM modules and Ruby Gems, as Gems are not Rails specific but rather the package manager for the Ruby language itself.
The activity on the Gems stats page does give you insight into the number of downloads there have been of Rails though.
So let’s compare the number of downloads of Express (a framework for Node.js) and Rails (both installable via their respective package managers). Both similar in that they are frameworks built on top of an existing language/library.
In the last month (so February 2015) there were 2,171,225 downloads of Express. Compare that to the number of downloads via Ruby Gems for the latest version of Ruby on Rails released December 20th, 2015 which have only totaled 541,249 in a two month period since its release.
Express had four times the number of downloads in the last month compared than Rails has had in the last two months. The numbers paint a picture of a framework not nearly as popular as it once was.
For update stats on Ruby Gem packages click here. For Node Package Manager statistics, simply visit their site and they’re displayed at the top of the homepage, individual stats are available on a packages detail page.
Looking to the Github repositories of Rails and Node.js, you can quite clearly see that Rails is being updated on a regular basis. Comparing the two, however, is more difficult stat-wise as Joyent don’t adopt such an open community model like Rails does.
Conclusion
Rumours of Ruby on Rails’ demise have been greatly exaggerated. Rails is not dying, you just forgot about it along with most of the other trend-riding chumps. Or your needs outgrew what Rails could provide you.
The stats quite clearly prove that Rails is not dying, but they also prove that it isn’t growing as much as Node.js is (or to be more specific and fair: Express). The community is still contributing to it and people are still using it.
You are only as good as your community and while Rails has a chance to turn things around in V5, for the moment, the low barrier to entry for Node.js thanks to Javascript makes it more appealing.
At the end of the day, use whatever works for you. Don’t believe the hype around a framework or language, if you like it and it meets your needs, then there is no wrong choice.
What are the problems you reference with Django? Are they similar to the rails ones or different?
For those with a Javascript background Node.js may be more approachable. But I still hold that for turning around a database driven app quickly, there is still nothing that comes even close to Ruby on Rails. Node.js callbacks are a maintainability nightmare.
Those who enjoy the language have stockholm syndrome.
Can you be so kind to swap “ruby on rails”(search term) with Ruby on Rails(web framework) in google trends showdown?
Here’s the right one https://www.google.com/trends/explore#q=%2Fm%2F0bbxf89%2C%20%2Fm%2F0505cl&cmpt=q&tz=
Rails has over a period become a big fat framework, and many committers boarded the rails ship and left once they had no more interest in it. To me it seems that number of commits is decreasing, and judging by enthusiasm during Keynote of Rails conf 2015 (and to some extent previous years), the core committers are running out of steam on this framework (or may be secretly planning to move out to new framework – who knows it may be node.js)
Thank you Ivan Denisov for pointing out that horrible error. Why can’t people do anything right these days?
:/
Since we’re comparing things in a VERY biased way. Here’s a very dishonest comparison between Rack and Node.js :
https://www.google.com/trends/explore#q=Rack%2C%20Node.js&cmpt=q&tz=Etc%2FGMT%2B4
They moved to PHP Laravel? ๐
Not sure how much weight I would give to download counts of Rails vs Express.
You download Express every time start a new app due to `npm install` vs. installing rails once per ruby version and running `bundle install` when switching apps.
Rails was the first web framework I really immersed myself in and used professionally. I was productive in it, the community seemed super-confident (if not downright smug), it was “where the smart people were” and I was a big believer in the way that Rails approached most things. In the past couple of years though a sense of obvious doubt and discomfort spread through the community and it was obvious that momentum had moved towards ther things (i.e. Node/JS).
Rails will be around for a long time – theres so many companies out there with Rails code to maintain. But I dont think the technology really has anything more to offer relative to things like Node or Go.
Rails was an amazing framework, I moved towards it after PHP and it taught me many new “professional” things, such as MVC, ORM, … and so on. But, Rails – imho – wanted to change too many things, and dumb down web developers. So in came the gazillion useless gems and coffee script. It seemed that nobody had to know any JS or HTML anymore, because somebody wrote a GEM for it, and the rails community would always favor that; You import a gem, use only 10% of it and even have to rewrite that a bit – but we could show off our Gemfile’s like it was a pissing content.
Learning a new language is hardly an argument here, Ruby is one of the most easy syntaxes and forgiving languages there are. Plus, we all copy/paste 80% of our code form other places anyway.
Rails got bloated, the community has been saying so since Rails 3, and nothing changed.
Give me Ruby and a decent ORM any day, with simple migrations and that would suffice. Oh wait, that’s what it was a few years ago.
They took a route to give, and keep on giving – regardless of what webdevs wanted. Maybe Rails5 or 6 will be a better platform again, but for now. I’m happy with the sleekness of Flask or Express
Come on man Node.js didn’t exist in 2004 to 2008 your statics are a fraud and thou Node.js is cool it can’t touch rails
RoR in my opinion was always a tool for hackers to hack together something quickly and then suffer death by thousand cuts as the exponential complexity function kicks in – which happens with most software that is ‘hacked together by software cowboys’. The next cab off the rank to suffer this fate will undoubtably be Angular as it is the latest honey pot for the ‘software cowboy’ swarm.
For me, I’ll stick to a well established language you chose because you already knew your stuff, you love object oriented development (and better still you ‘get it’) and when you saw it you thought – ah, that will let me do my stuff better and most definitely DID NOT say “Everyone else seems to be using it – therefore it must be good!”
i fervently use opal to compile ruby to javascript
github.com/opal/opal/
in that sense existing vast code of ruby has taken rebirth for nodejs and browser run.
even this “firefox addon” of asciidoctorjs has not been written in javascript. It has been written in ruby, which has been compiled(using opal) to javascript and then running in firefox. Opal is quite stable and useful
Many projects which we deliver in ruby, are run on jvm using jruby.
I hope that If tomorrow, ruby transpiles to run on PHP, then it will easily reinvent to be supported on vast number of cheap hosts.
or, even transpiling “ruby to python” will enable it to access vast number of python libraries in scientific domain. And will push scientific adoption.
So, ruby does not need ‘more features’ to escape from slow death(ie, no new adoption), it needs stable implementations on top of pythonVM and PHP. That will keep it driving.
Hi, I did my own research, being inspired by your comments on the topic: http://odiseev.com/2016/08/10/is-ruby-dying/. Thanks a ton!
Ruby on Rails isn’t dead as long as you aren’t trying to find a job using it, in which case it was dead on arrival.
Few are the elegant languages out there with little quirks.
Agree with the point that Rails is not dying but yes it’s not growing at much.