Here to stay - Analyzing RubyGems stats for 2018
Tags: ruby, rails, gems, programming
Published: 2019-01-22 19:10:05

---
title: Here to stay - Analyzing RubyGems stats for 2018
published: true
description: What's up with Ruby?
tags: ruby, rails, gems, programming
cover_image: https://thepracticaldev.s3.amazonaws.com/i/loe6sz146wmi33g1l6ct.jpg
---
As years go by, there is always a question of whether Ruby is dead or alive, and as usual, we have done our research and compiled some statistics about Ruby’s 2018 lifeline that might help you find an answer.

2018 was an interesting year in terms of gems. Some increased, and some decreased their download numbers. Some were well maintained, while others could have used a helping hand. We have also seen a few newcomers that almost made it to the top of their categories. As for the language itself, at the end of 2018, [Ruby 2.6](https://www.ruby-lang.org/en/news/2018/12/25/ruby-2-6-0-released/) was released, getting us a few steps closer to achieving the [Ruby 3×3 goals](https://blog.heroku.com/ruby-3-by-3). The most notable improvement in this release was the brand new (experimental) [JIT compiler](https://medium.com/@k0kubun/ruby-2-6-jit-progress-and-future-84e0a830ecbf) that should boost the performance of Ruby programs.

##Sources
The data used for generating the statistics below were obtained from two sources – the latest RubyGems [PG-dump](https://rubygems.org/pages/data) and [BestGems](http://bestgems.org/). The latter keeps track of all daily gem downloads and exposes this data through their API. Having that and [Vedran’s](https://github.com/vr4b4c) awesome [script](https://gist.github.com/NBuhinicek/c2373ed296d0033a56849a0a2024148b), which made it pretty easy to browse through the numbers, we have compared some of the most used gems.

Bear in mind that some of these downloads are a direct result of gem dependencies, non-cached CI builds, and gem mirroring services. There is still a strong correlation between the number of gem downloads and the number of its active users, but we feel it’s important to make it clear that these two numbers are not exactly the same.

## Gem creation & releases
![rubygems stats 2018 – gem creation](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uzinsg95vvcdwotbg05u.png)
Unfortunately, this was another year in a row that the creation of new gems decreased even further. That’s not so surprising after all because there already is a huge number of gems that are well-known, well-maintained, and cover a lot of common use cases. To make a new gem in a field that’s already well covered is a real quest, but not impossible. Further down, we will introduce a gem that managed to make a huge dent in the JSON:API field.

![rubygems stats 2018 – gem releases](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0uhptpfhgmse62xcsjvs.png)
As for the creation of gems, a downhill trend is also evident in the number of gem releases. But you can’t get one without the other. Older and well-maintained gems usually get a few new minor releases and a major release in a calendar year. Newer gems that are still in infancy usually have more code churn, breaking changes, and consequently releases.

## Rails downloads
![rubygems stats 2018 – rails downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9dss8w4kpxn9wgf385h8.png)
In 2018, the number of [Rails](https://github.com/rails/rails) downloads had increased again. It had its ups and downs, but it held around the 3 million download mark. As the end of the year came, we heard a lot about the new major release, [Rails 6](https://edgeguides.rubyonrails.org/6_0_release_notes.html). People jumped on the hype train raising the number of monthly downloads to almost 4 million.

[Action Mailbox](https://github.com/rails/rails/pull/34786), [Action Text](https://github.com/rails/rails/pull/34873), and parallel testing are the most anticipated additions, but there will be more improvements included in Rails 6. We will need to be patient though, as the release is scheduled for the end of April 2019.

## Other web frameworks
### Sinatra – still falling behind
![rubygems stats 2018 – sinatra downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0cvkudpdgbfqy4dv7of8.png)
When [Sinatra](https://github.com/sinatra/sinatra) got a new maintainer in 2017, and they pushed a new [2.0 release](http://sinatrarb.com/2017/05/15/sinatra-two-point-oh.html), things started to look better and the upward trend continued into 2018 as well. Having just five patches throughout the year, they reached 1,5 million downloads as their monthly standard, pushing it to the all-time high of just above 2 million downloads at the end of 2018.

![rubygems stats 2018 – padrino and hanami downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/l8mberf8dfejwz16j6cx.png)
On the other side of the download spectre, [Padrino](https://github.com/padrino/padrino-framework) yearly downloads fell by 10%, while [Hanami](https://github.com/hanami/hanami) downloads increased by about 33%. Hanami’s core team is currently working on version 2.0, which could be something to look out for in 2019. Their download numbers are much lower compared to Rails and Sinatra but that doesn’t detract from the fact that there are people that find them more suitable for their use cases and see potential in their further development. Having options to choose from is always a positive thing.

## Database adapters
![rubygems stats 2018 – ruby database adapters](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ybae5r07u1wbaidm9upx.png)
For PG and [MySQL2](https://github.com/brianmario/mysql2) 2018 was a great year. PG managed to increase their numbers for 4, and MySQL2 for 5 million downloads. [SQLite3](https://github.com/sparklemotion/sqlite3-ruby), on the other hand, experienced a drastic drop to only one-third of the downloads made in 2017 (from 21 to 8 million yearly downloads).

## Application servers
![rubygems stats 2018 – puma and thin downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/os58n38jvvq1t3pf55kj.png)
The situation here is pretty much the same as the year before. [Puma](https://github.com/puma/puma), the default server for Rails, is still in the number one spot. And [Thin](https://github.com/macournoyer/thin), with no new releases in the past year, actually made a 250 thousand drop.

![rubygems stats 2018 – unicorn and passenger downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/52emznphi022hsi2m6my.png)
[Unicorn](https://bogomips.org/unicorn.git), although better maintained than Thin, didn’t manage to increase the number of downloads compared to 2017. Developers behind [Passenger](https://github.com/phusion/passenger), on the other side, are putting a lot of work into new releases, having a [6.0 version](https://github.com/phusion/passenger/releases/tag/release-6.0.0) released at the end of November and managing to triple their download numbers since 2017. They had a huge spike in the middle of the year, recording more downloads in one month than in the last two years combined.

## Other ORMs
![rubygems stats 2018 – sequel downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/almyd7bcv8z12oaklkyr.png)
2018 maybe wasn’t the best year for [Sequel](https://github.com/jeremyevans/sequel), as its downloads dropped by 14%. Sequel is well maintained and has a status that just a few gems have – 0 outstanding issues. Other than that, we could mention rom-rb, which is maybe not a strict ORM, but has the same uses. It had a small growth during the year, recording just over 90 thousand downloads.

## Testing
![rubygems stats 2018 – ruby testing](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/eso5dlpf2hx724z73jms.png)
For [RSpec](https://github.com/rspec/rspec) it seems that only the sky’s the limit. Its downloads more than doubled hitting almost 200 million. Even though it’s defined as a development dependency in a lot of gems, it’s not used as a runtime dependency that often. The vast majority of the downloads thus stem from actual project uses. [Minitest](https://github.com/seattlerb/minitest), on the other hand, gained a bit more popularity, although there are some open issues and the last release was just under 12 months ago. All in all, it’s great to see these numbers skyrocket because that just means that people are testing their programs more and that the testing culture is evolving even further.

## Debugging
![rubygems stats 2018 – ruby debugging](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/c2lcjwydu19nc78vgnav.png)
It is inevitable that bugs will occur during software development, but we can examine them easily using the following gems. The downloads of [pry](https://github.com/pry/pry), [irb’s](https://github.com/ruby/irb) number one enemy, jumped by 50%, but this number is eclipsed by the number of open issues – 177 as of writing this article. [Byebug](https://github.com/deivid-rodriguez/byebug), which is just below pry, has a download number that is growing even faster, presumably because they started 2018 by releasing [version 10.0](https://github.com/deivid-rodriguez/byebug/releases/tag/v10.0.0).

Another interesting debugging tool – [Better Errors](https://github.com/BetterErrors/better_errors). They replaced the standard Rails error page with their own, where except the usual stacktrace, you can also debug your code as you were in a debugger. It had a consistent growth rate that continued into 2018 as well. Well maintained and released, it is a very helpful gem to have up your sleeve.

## Background workers
![rubygems stats 2018 – ruby background workers](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/skm3oc5xwnpyn0b5hwxy.png)
The situation here is the same as the year before. [Sidekiq](https://github.com/mperham/sidekiq/) is way ahead of [Delayed::Job](https://github.com/collectiveidea/delayed_job) and [Resque](https://github.com/resque/resque), by 10 million downloads.. By removing even more dependencies and constantly improving and releasing, Sidekiq has become much faster and leaner than its competitors. Resque dropped a [2.0 release](https://github.com/resque/resque/releases/tag/v2.0.0) in November, but there are no spikes visible on our graph. Comparing it to Delayed::Job, their numbers matched each other throughout the year.

## Authorization
![rubygems stats 2018 – cancancan and pundit downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/6whcxftv5h1iwjcth14j.png)
The authorization has been pretty stable too. CanCanCan is still in the lead, while Pundit came in second with 7 million downloads less. While CanCanCan’s downloads were falling through the year, Pundit’s, on the other hand, were stable until July and then started to increase. The reason for that is the 2.0 release, which Pundit fans had been waiting for more than two years. Pundit could take the cake and dethrone CanCanCan if the download trend continues into 2019.

## Administration
![rubygems stats 2018 – ruby administration](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0x6j1iy3fq41mxodjhj3.png)
It was a big year for [Active Admin](https://github.com/activeadmin/activeadmin), its downloads doubled and it left [Rails Admin](https://github.com/sferik/rails_admin) far behind. Both are still well maintained and follow similar release cycles.

## JSON:API Specifications
![rubygems stats 2018 – json api specification](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k1cvc2p9rkwr3lxfkgui.png)
This is a big one. The most popular and talked-about gem in the [JSON:API](https://jsonapi.org/) world, [Fast JSON API](https://github.com/Netflix/fast_jsonapi) by Netflix, which was first released in February 2018, surpassed [JSONAPI-rb](https://github.com/jsonapi-rb/jsonapi-rb) on a yearly download base, and it could soon become THE gem to use for JSON:API serialization. JSONAPI-rb missed a whole year in terms of releases, and at [JSONAPI::Resources](https://github.com/cerebris/jsonapi-resources), the issues slowly piling up. Having that in mind, it’s no wonder that there are ever more migrations to the newcomer, that is well maintained and cared for.

## File uploaders
![rubygems stats 2018 – carrierwave and paperclip downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n3qet1r4j88kfpqo6rdm.png)
2018 wasn’t the best year for [CarrierWave](https://github.com/carrierwaveuploader/carrierwave/) and it was even worse for [Paperclip](https://github.com/thoughtbot/paperclip), which was [deprecated](https://robots.thoughtbot.com/closing-the-trombone). Both were well maintained, and released often, but they managed to get just 20-30% more downloads than in 2017. Finishing the year as equals and not actually growing that much are signs that something’s off.

The reason for that is just what we predicted last year as a possible game-changer – [Active Storage](https://github.com/rails/rails/tree/v5.2.2/activestorage). Available from Rails 5.2 onwards, it gained a lot of popularity and finished the year with 5 million downloads.

![rubygems stats 2018 – shrine downloads](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wtk28x0cs6fv9kg7rz12.png)
[Shrine](https://github.com/shrinerb/shrine) is another great solution for file upload management. While the numbers seem low, having been downloaded just over 300 thousand times, it offers a lot of advantages over the more popular choices, with generality, simplicity, and modularity being at the forefront.

## Aggregated stats for 2018
![rubygems stats 2018 – aggregated stats](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1gc13m0vcl87o2w2hwox.png)
The number of Rails downloads continued to grow and reached 37,5 million. 29 new gems were published daily on average. 260 new gem releases were published daily on average. Taking into consideration just the gems mentioned in this post, total downloads jumped from 389,794,028 in 2017 to 499,035,801 in 2018. That’s a 28% increase in just one year!

# Conclusion
As in the previous years, 2018 was another successful year for Ruby, and if after all of these numbers, the state of Ruby is not clear to you, let us assure you that it is here to stay. We are not the only [ones](https://naturaily.com/blog/who-gives-f-about-rails) that came to this conclusion.

With more than 3,700 contributors and new ones coming in on a daily basis, Rails is way ahead of, for example, Django, which has just over 1,600 contributors. That number of Rails backers just proves that Ruby has a strong community that is involved in Rails development and makes a lot of gems that in the end, help other developers build awesome applications better and faster.

Maybe Ruby isn’t the number one language to pick in terms of performance, as there are many more performant choices. But it is clear that performance is of great importance with the latest Ruby releases just by looking at the GC and JIT changes done by the Ruby Core team. Achieving the 3×3 promise (Ruby 3.0 being three times faster 2.0) thus seems closer by the day.

So, buckle up, as there are a lot of things about to change. And in the meanwhile, if you want to dig into the data feel free to download it [here](https://photos.infinum.com/store/cfb5dfae248ef1dc1a4a6695e956c742.pdf).