Ruby Database Tools

Open-source Ruby projects categorized as Database Tools

Top 23 Ruby Database Tool Projects

  • PgHero

    A performance dashboard for Postgres

    Project mention: Is there something like, for checking how long rails queries and functions take to execute? | | 2022-04-03 (open source equivalent to pganalyze)

  • Blazer

    Business intelligence made simple

    Project mention: Italian watchdog bans use of Google Analytics | | 2022-06-23

    I use Ahoy too, but I don't have very good visibility into the data. I should spend more time building queries and creating charts. I should probably set up blazer as well:

  • Scout APM

    Truly a developer’s best friend. Scout APM is great for developers who want to find and fix performance issues in their applications. With Scout, we'll take care of the bugs so you can focus on building great things 🚀.

  • strong_migrations

    Catch unsafe migrations in development

    Project mention: [AskJS] Is there any alternative to the strong migrations gem? | | 2022-10-07

    The strong migrations gem in Rails alerts when you're trying to make a migration that may be dangerous. Does anyone know an alternative for Javascript? Or maybe for raw SQL.

  • Scenic

    Versioned database views for Rails

    Project mention: Utilizando views SQL no Ruby on Rails | | 2022-03-28
  • Database Cleaner

    Strategies for cleaning databases in Ruby. Can be used to ensure a clean state for testing.

  • Large Hadron Migrator

    Online MySQL schema migrations

    Project mention: GitHub downtime root cause analysis | | 2021-12-03

    No you didn't. They're doing what is often referred as "online schema change" using (but the concept is the same than percona's pt-online-schema-change, or

  • Lol DBA

    lol_dba is a small package of rake tasks that scan your application models and displays a list of columns that probably should be indexed. Also, it can generate .sql migration scripts.

  • InfluxDB

    Build time-series-based applications quickly and at scale.. InfluxDB is the Time Series Data Platform where developers build real-time applications for analytics, IoT and cloud-native services in less time with less code.

  • Seed dump

    Rails 4/5 task to dump your data to db/seeds.rb

    Project mention: Rails - A Hidden Gem: Seed Dump | | 2022-10-19

    During the testing of this functionality, you're adding data to your database. Rather than resetting your database, what if you utilized the information you entered? What if this is how you could build your seed file, rather than creating it from scratch? Or what if you do some testing and just want to add a couple of live examples to your seed file? Enter Seed Dump.

  • Squasher

    Squasher - squash your old migrations in a single command

  • Foreigner

    Adds foreign key helpers to migrations and correctly dumps foreign keys to schema.rb

  • active_record_doctor

    Identify database issues before they hit production.

    Project mention: Troubleshooting a RoR Application in Production | | 2022-05-24

    Start with finding mixing indexes:

  • Seed Fu

    Advanced seed data handling for Rails, combining the best practices of several methods together.

  • Seedbank

    Seedbank gives your seed data a little structure. Create seeds for each environment, share seeds between environments and specify dependencies to load your seeds in order. All nicely integrated with simple rake tasks.

  • BatchLoader

    :zap: Powerful tool for avoiding N+1 DB or HTTP queries

    Project mention: N+1 problem will never be an issue with N1Loader gem | | 2022-01-22

    Interesting, I've just been researching Dataloader implementations for Ruby and have between trying to decide between GraphQL::Dataloader, graphql-batch and BatchLoader. I'll give this a look as well. Can you also make API calls inside the loaders?

  • Polo

    Polo travels through your database and creates sample snapshots so you can work with real world data in development.

  • Upsert

    Upsert on MySQL, PostgreSQL, and SQLite3. Transparently creates functions (UDF) for MySQL and PostgreSQL; on SQLite3, uses INSERT OR IGNORE.

  • DatabaseConsistency

    The tool to avoid various issues due to inconsistencies and inefficiencies between a database schema and application models.

    Project mention: Enhanced ActiveRecord preloading | | 2022-05-19

    Described issues may be found with DatabaseConsistency.

  • DatabaseValidations

    Database validations for ActiveRecord

    Project mention: Ecto's uniqueness constraint vs. Rails' uniqueness validation | | 2022-05-21

    Love this post, great exploration of the nuances of uniqueness validations.

    I came here to mention that there is also the gem which allows you to handle uniqueness validations in Rails in a similar manner to Ecto.

  • online_migrations

    Catch unsafe PostgreSQL migrations in development and run them easier in production (code helpers for table/column renaming, changing column type, adding columns with default, background migrations, etc).

    Project mention: Zero-downtime schema migrations for Ruby on Rails | | 2022-05-25

    For other people looking into zero-downtime migrations: you may also consider easier to use ruby-based tool for this

  • Shiba

    Catch bad SQL queries before they cause problems in production

  • QueryTrack

    Find time-consuming database queries for ActiveRecord-based Rails Apps

  • fast_page

    Blazing fast pagination for ActiveRecord with deferred joins ⚡️

    Project mention: We switched to cursor-based pagination | | 2022-08-21

    There are ways to mitigate the (although not eliminate) the slowing down of offset/limit pagination in later pages. The technique is called a "deferred join" and it is most effective in MySQL. The basic idea is to paginate as little data as necessary, and then do a self-join to get the rest of the data for a single page.

    You can read more about it here: or here

    There are libraries for Laravel ( and Rails ( as well!

    Cursor based pagination is wonderful, but sometimes you're stuck with offset/limit for whatever reason. Might as well make it fast.

  • SecondBase

    Seamless second database integration for Rails.

  • SonarLint

    Clean code begins in your IDE with SonarLint. Up your coding game and discover issues early. SonarLint is a free plugin that helps you find & fix bugs and security issues from the moment you start writing code. Install from your favorite IDE marketplace today.

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020). The latest post mention was on 2022-10-19.

Ruby Database Tools related posts


What are some of the best open-source Database Tool projects in Ruby? This list will help you:

Project Stars
1 PgHero 6,737
2 Blazer 3,396
3 strong_migrations 3,289
4 Scenic 3,062
5 Database Cleaner 2,826
6 Large Hadron Migrator 1,773
7 Lol DBA 1,476
8 Seed dump 1,386
9 Squasher 1,371
10 Foreigner 1,338
11 active_record_doctor 1,255
12 Seed Fu 1,203
13 Seedbank 1,107
14 BatchLoader 948
15 Polo 720
16 Upsert 657
17 DatabaseConsistency 641
18 DatabaseValidations 400
19 online_migrations 370
20 Shiba 290
21 QueryTrack 281
22 fast_page 219
23 SecondBase 218
Delete the most useless function ever: context switching.
Zigi monitors Jira and GitHub updates, pings you when PRs need approval and lets you take fast actions - all directly from Slack! Plus it reduces cycle time by up to 75%.