๐Ÿ’Ž

Ruby on Rails

Ruby on Rails is a full-stack web framework created by David Heinemeier Hansson and maintained by the Rails core team alongside a long-running open-source community. It's the #20 most-used web framework, reported in roughly 5.9% of developer surveys. Rails popularized the "convention over configuration" philosophy โ€” sensible defaults, an ActiveRecord ORM, and code-generating scaffolding โ€” and its productivity-first design directly influenced nearly every batteries-included framework that came after it, including Laravel and Django.

Quick facts
Type: Full-stack MVC web framework
Made by: David Heinemeier Hansson / Rails core team (open-source)
License: Free / open-source (MIT)
Language: Ruby
Primary use case: Rapidly building database-backed web applications with minimal boilerplate
Jump to: ExampleGetting startedBest for

Example

A Rails model built on ActiveRecord maps directly to a database table, and a controller action can query it with almost no extra code.

# app/models/post.rb
class Post < ApplicationRecord
  validates :title, presence: true
  belongs_to :author
  has_many :comments
end

# app/controllers/posts_controller.rb
class PostsController < ApplicationController
  def show
    @post = Post.find(params[:id])
    render json: @post
  end
end

Getting started

Install the Rails gem, then use its generator to scaffold a brand-new application with a working database connection.

# install Rails and create a new app
gem install rails
rails new my_app

cd my_app
rails server
Best for: Startups and small teams that need to go from idea to a working, database-backed web app quickly โ€” content platforms, marketplaces, and internal admin tools where Rails' generators and conventions save weeks of setup.