Welcome to Rails What's Rails? Rails is a web application framework that includes everything needed to create database-backed web applications according to the Model-View-Controller (MVC) pattern. Understanding the MVC pattern…
Welcome to Rails
What's Rails?
Rails is a web application framework that includes everything needed to
create database-backed web applications according to the
Model-View-Controller (MVC)
pattern.
Understanding the MVC pattern is key to understanding Rails. MVC divides your
application into three layers: Model, View, and Controller, each with a specific responsibility.
Model layer
The _Model layer_ represents the domain model (such as Account, Product,
Person, Post, etc.) and encapsulates the business logic specific to
your application. In Rails, database-backed model classes are derived fromActiveRecord::Base. [Active Record](activerecord/README.rdoc) allows you to present the data from
database rows as objects and embellish these data objects with business logic
methods.
Although most Rails models are backed by a database, models can also be ordinary
Ruby classes, or Ruby classes that implement a set of interfaces as provided by
the [Active Model](activemodel/README.rdoc) module.
View layer
The _View layer_ is composed of "templates" that are responsible for providing
appropriate representations of your application's resources. Templates can
come in a variety of formats, but most view templates are HTML with embedded
Ruby code (ERB files). Views are typically rendered to generate a controller response
or to generate the body of an email. In Rails, View generation is handled by [Action View](actionview/README.rdoc).
Controller layer
The _Controller layer_ is responsible for handling incoming HTTP requests and
providing a suitable response. Usually, this means returning HTML, but Rails controllers
can also generate XML, JSON, PDFs, mobile-specific views, and more. Controllers load and
manipulate models, and render view templates in order to generate the appropriate HTTP response.
In Rails, incoming requests are routed by Action Dispatch to an appropriate controller, and
controller classes are derived from ActionController::Base. Action Dispatch and Action Controller
are bundled together in [Action Pack](actionpack/README.rdoc).
Frameworks and libraries
[Active Record](activerecord/README.rdoc), [Active Model](activemodel/README.rdoc), [Action Pack](actionpack/README.rdoc), and [Action View](actionview/README.rdoc) can each be used independently outside Rails.
In addition to that, Rails also comes with:
- [Action Mailer](actionmailer/README.rdoc), a library to generate and send emails
- [Action Mailbox](actionmailbox/README.md), a library to receive emails within a Rails application
- [Active Job](activejob/README.md), a framework for declaring jobs and making them run on a variety of queuing backends
- [Action Cable](actioncable/README.md), a framework to integrate WebSockets with a Rails application
- [Active Storage](activestorage/README.md), a library to attach cloud and local files to Rails applications
- [Action Text](actiontext/README.md), a library to handle rich text content
- [Active Support](activesupport/README.rdoc), a collection of utility classes and standard library extensions that are useful for Rails, and may also be used independently outside Rails
Getting Started
1. Install Rails at the command prompt if you haven't yet:
bash
$ gem install rails
2. At the command prompt, create a new Rails application:
bash
$ rails new myapp
where "myapp" is the application name.
3. Change directory to myapp and start the web server:
bash
$ cd myapp
$ bin/rails server
Run with --help or -h for options.
4. Go to http://localhost:3000 and you'll see the Rails bootscreen with your Rails and Ruby versions.
5. Follow the guidelines to start developing your application. You may find
the following resources handy:
* Getting Started with Rails
* Ruby on Rails Guides
* The API Documentation
Contributing
We encourage you to contribute to Ruby on Rails! Please check out the
Contributing to Ruby on Rails guide for guidelines about how to proceed. Join us!
Trying to report a possible security vulnerability in Rails? Please
check out our security policy for
guidelines about how to proceed.
Everyone interacting in Rails and its sub-projects' codebases, issue trackers, chat rooms, and mailing lists is expected to follow the Rails code of conduct.
License
Ruby on Rails is released under the MIT License.
-
rails
Ruby on Rails
Ruby ★ 59k 1h agoExplain → -
webpacker
Use Webpack to manage app-like JavaScript modules in Rails
Ruby ★ 5.3k 2y agoExplain → -
thor
Thor is a toolkit for building powerful command-line interfaces.
Ruby ★ 5.3k 12d agoExplain → -
jbuilder
Jbuilder: generate JSON objects with a Builder-style DSL
Ruby ★ 4.4k 1mo agoExplain → -
spring
Rails application preloader
Ruby ★ 2.8k 18d agoExplain → -
bootsnap
Boot large Ruby/Rails apps faster
Ruby ★ 2.7k 20d agoExplain → -
jquery-ujs
Ruby on Rails unobtrusive scripting adapter for jQuery
JavaScript ★ 2.6k 2y agoExplain → -
solid_queue
Database-backed Active Job backend
Ruby ★ 2.5k 4h agoExplain → -
arel ⑂
A Relational Algebra
Ruby ★ 2.0k 7y agoExplain → -
rails-dev-box
A virtual machine for Ruby on Rails core development
Shell ★ 2.0k 1mo agoExplain → -
tailwindcss-rails
No description.
Ruby ★ 1.6k 2d agoExplain → -
web-console ⑂
Rails Console on the Browser.
Ruby ★ 1.4k 4mo agoExplain → -
activeresource
Connects business objects and REST web services
Ruby ★ 1.4k 1mo agoExplain → -
kredis
Higher-level data structures built on Redis
Ruby ★ 1.4k 7mo agoExplain → -
docked
Running Rails from Docker for easy start to development
Dockerfile ★ 1.3k 1y agoExplain → -
globalid
Identify app models with a URI
Ruby ★ 1.3k 5d agoExplain → -
strong_parameters ▣
Taint and required checking for Action Pack and enforcement in Active Model
Ruby ★ 1.3k 9y agoExplain → -
importmap-rails
Use ESM with importmap to manage modern JavaScript in Rails without transpiling or bundling.
Ruby ★ 1.2k 6mo agoExplain → -
actioncable ▣
Framework for real-time communication over websockets
★ 1.1k 8y agoExplain → -
mission_control-jobs
Dashboard and Active Job extensions to operate and troubleshoot background jobs
Ruby ★ 1.0k 6mo agoExplain → -
propshaft
Deliver assets for Rails
Ruby ★ 1.0k 8d agoExplain → -
solid_cache
A database-backed ActiveSupport::Cache::Store
Ruby ★ 1.0k 2mo agoExplain → -
sprockets
Rack-based asset packaging system
Ruby ★ 984 1d agoExplain → -
jquery-rails
A gem to automate using jQuery with Rails
Ruby ★ 943 9mo agoExplain → -
jsbundling-rails
Bundle and transpile JavaScript in Rails with esbuild, rollup.js, bun, or Webpack.
Ruby ★ 923 1mo agoExplain → -
sass-rails
Ruby on Rails stylesheet engine for Sass
Ruby ★ 859 5y agoExplain → -
exception_notification ▣
NOTICE: official repository moved to https://github.com/smartinez87/exception_notification
Ruby ★ 831 11y agoExplain → -
sdoc
Standalone sdoc generator
JavaScript ★ 824 9mo agoExplain → -
rails-perftest
Benchmark and profile your Rails apps
Ruby ★ 799 4y agoExplain → -
activejob ▣
Declare job classes that can be run by a variety of queueing backends
Ruby ★ 741 10y agoExplain → -
activestorage ▣
Store files in Rails applications
★ 729 9y agoExplain → -
actioncable-examples ▣
Action Cable Examples
Ruby ★ 664 3y agoExplain → -
pjax_rails
PJAX integration for Rails
Ruby ★ 659 5y agoExplain → -
cssbundling-rails
Bundle and process CSS in Rails with Tailwind, PostCSS, and Sass via Node.js.
Ruby ★ 641 8mo agoExplain → -
cache_digests ▣
No description.
Ruby ★ 633 12y agoExplain → -
activerecord-session_store
Active Record's Session Store extracted from Rails
Ruby ★ 600 4d agoExplain → -
sprockets-rails
Sprockets Rails integration
Ruby ★ 592 1y agoExplain → -
execjs
Run JavaScript code from Ruby
Ruby ★ 573 1mo agoExplain → -
rubocop-rails-omakase
Omakase Ruby styling for Rails
Ruby ★ 557 6mo agoExplain → -
rails-observers
Rails observer (removed from core in Rails 4.0)
Ruby ★ 522 3y agoExplain → -
action_push_native
Rails push notifications for mobile platforms
Ruby ★ 471 3mo agoExplain → -
marcel
Find the mime type of files, examining file, filename and declared type
Ruby ★ 454 1mo agoExplain → -
rails_upgrade ⑂
Plugin to run checks on your Rails 2.x/3.x to check for obvious upgrade points on the path to 3.0
Ruby ★ 441 14y agoExplain → -
request.js
No description.
JavaScript ★ 439 4mo agoExplain → -
actiontext ▣
Edit and display rich text in Rails applications
★ 405 7y agoExplain → -
acts_as_list ▣
NOTICE: official repository moved to https://github.com/swanandp/acts_as_list
Ruby ★ 384 10y agoExplain → -
actionpack-page_caching
Static page caching for Action Pack (removed from core in Rails 4.0)
Ruby ★ 355 5y agoExplain → -
rails-html-sanitizer
No description.
Ruby ★ 341 1d agoExplain → -
solid_cable
A database backed ActionCable adapter
Ruby ★ 339 1h agoExplain → -
commands
Run Rake/Rails commands through the console
Ruby ★ 339 9y agoExplain → -
rails-controller-testing
Brings back `assigns` and `assert_template` to your Rails tests
Ruby ★ 332 3y agoExplain → -
rails-new
Create Rails projects without Ruby installed
Rust ★ 318 19d agoExplain → -
ssl_requirement ▣
NOTICE: official repository moved to https://github.com/retr0h/ssl_requirement
Ruby ★ 316 9y agoExplain → -
acts_as_tree
NOTICE: official repository moved to https://github.com/amerine/acts_as_tree
Ruby ★ 286 18y agoExplain → -
open_id_authentication
NOTICE: official repository moved to https://github.com/Velir/open_id_authentication
Ruby ★ 283 15y agoExplain → -
actionpack-action_caching
Action caching for Action Pack (removed from core in Rails 4.0)
Ruby ★ 266 3y agoExplain → -
dartsass-rails
Integrate Dart Sass with the asset pipeline in Rails
Ruby ★ 251 1y agoExplain → -
coffee-rails ⑂
CoffeeScript adapter for the Rails asset pipeline. Also adds support for .coffee views.
Ruby ★ 233 2y agoExplain → -
protected_attributes
Protect attributes from mass-assignment in ActiveRecord models.
Ruby ★ 231 2y agoExplain → -
in_place_editing
NOTICE: official repository moved to https://github.com/amerine/in_place_editing
Ruby ★ 229 17y agoExplain → -
journey ▣
A router for rails
Ruby ★ 217 9y agoExplain → -
auto_complete
NOTICE: official repository moved to https://github.com/david-kerins/auto_complete
Ruby ★ 209 18y agoExplain → -
rails-dom-testing
Extracting DomAssertions and SelectorAssertions from ActionView.
Ruby ★ 195 2mo agoExplain → -
dynamic_form
NOTICE: official repository moved to https://github.com/joelmoss/dynamic_form
Ruby ★ 191 4y agoExplain → -
country_select ▣
NOTICE: official repository moved to https://github.com/stefanpenner/country_select
Ruby ★ 175 8y agoExplain → -
requestjs-rails
No description.
JavaScript ★ 156 6mo agoExplain → -
routing_concerns
Abstract common routing resource concerns to cut down on duplication.
Ruby ★ 153 14y agoExplain → -
esbuild-rails ▣
Bundle and transpile JavaScript in Rails with esbuild
Ruby ★ 144 4y agoExplain → -
rails-contributors
The web application that runs https://contributors.rubyonrails.org
Ruby ★ 138 3d agoExplain → -
actionmailbox ▣
Receive and process incoming emails in Rails
★ 126 7y agoExplain → -
devcontainer
No description.
Ruby ★ 105 2d agoExplain → -
rails_xss ⑂
A plugin for rails 2.3 apps which switches the default to escape by default
Ruby ★ 105 13y agoExplain → -
website
No description.
HTML ★ 98 7h agoExplain → -
activemodel-globalid ▣
Serializing models to a single string makes it easy to pass references around
Ruby ★ 90 12y agoExplain → -
account_location
NOTICE: official repository moved to https://github.com/bbommarito/account_location
Ruby ★ 72 18y agoExplain → -
acts_as_nested_set
NOTICE: official repository moved to https://github.com/bbommarito/acts_as_nested_set
Ruby ★ 70 18y agoExplain → -
activerecord-deprecated_finders
No description.
Ruby ★ 70 10y agoExplain → -
iso-3166-country-select
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 70 18y agoExplain → -
activemodel-serializers-xml
No description.
Ruby ★ 68 1y agoExplain → -
spring-watcher-listen
No description.
Ruby ★ 65 3y agoExplain → -
prototype-ujs
No description.
JavaScript ★ 62 14y agoExplain → -
weblog ▣
Superseded by https://github.com/rails/website
HTML ★ 62 4y agoExplain → -
prototype_legacy_helper ▣
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 60 9y agoExplain → -
verification
NOTICE: official repository moved to https://github.com/sikachu/verification
Ruby ★ 58 15y agoExplain → -
conductor ⑂
Conductor is a Rails engine that lets you do through a web UI what you'd normally do with the rails shell command.
Ruby ★ 55 7y agoExplain → -
prototype-rails
Add RJS, Prototype, and Scriptaculous helpers to Rails 3.1+ apps
Ruby ★ 53 4y agoExplain → -
builder ⑂
Provide a simple way to create XML markup and data structures.
Ruby ★ 50 2y agoExplain → -
homepage ▣
Superseded by https://github.com/rails/website
HTML ★ 50 4y agoExplain → -
record_tag_helper
ActionView Record Tag Helpers
Ruby ★ 50 2y agoExplain → -
actionpack-xml_parser
XML parameters parser for Action Pack (removed from core in Rails 4.0)
Ruby ★ 49 9y agoExplain → -
rollupjs-rails ▣
Bundle and transpile JavaScript in Rails with rollup.js
Ruby ★ 48 4y agoExplain → -
activesupport-json_encoder
No description.
Ruby ★ 48 7y agoExplain → -
etagger
Declare what goes in to your ETags: asset versions, account ID, etc.
Ruby ★ 41 13y agoExplain → -
render_component
NOTICE: official repository moved to https://github.com/malev/render_component. Components allow you to call other actions for their rendered response while executing another action
Ruby ★ 40 17y agoExplain → -
upload_progress
NOTICE: official repository moved to https://github.com/rishav/upload_progress
Ruby ★ 39 18y agoExplain → -
atom_feed_helper
NOTICE: official repository moved to https://github.com/TrevorBramble/atom_feed_helper
Ruby ★ 38 18y agoExplain → -
gsoc2014
Project website and wiki for Ruby on Rails proposals to Google Summer of Code 2014
★ 37 12y agoExplain → -
gsoc2013 ▣
Project website and wiki for Ruby on Rails proposals to Google Summer of Code 2013
★ 30 13y agoExplain → -
rails-docs-server
No description.
Ruby ★ 28 5mo agoExplain → -
ruby-coffee-script
Ruby CoffeeScript Compiler
Ruby ★ 28 5y agoExplain → -
deadlock_retry
NOTICE: official repository moved to https://github.com/heaps/deadlock_retry
Ruby ★ 28 18y agoExplain → -
asset_server
NOTICE: official repository moved to https://github.com/andhapp/asset_server
Ruby ★ 27 16y agoExplain → -
homepage-2011 ▣
This repo is now legacy. New homepage is at rails/homepage
HTML ★ 26 10y agoExplain → -
token_generator
NOTICE: official repository moved to https://github.com/bbommarito/token_generator
Ruby ★ 25 18y agoExplain → -
buildkite-config
Fallback configuration for branches that lack a .buildkite/ directory
Ruby ★ 23 25d agoExplain → -
http_authentication
NOTICE: official repository moved to https://github.com/dshimy/http_authentication
Ruby ★ 22 18y agoExplain → -
irs_process_scripts
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core. The extracted inspector, reaper, and spawner scripts from script/process/*
★ 22 17y agoExplain → -
javascript_test
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
JavaScript ★ 19 5y agoExplain → -
scriptaculous_slider
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
JavaScript ★ 18 18y agoExplain → -
rails-ujs ▣
Ruby on Rails unobtrusive scripting adapter
★ 17 9y agoExplain → -
scaffolding
NOTICE: official repository moved to https://github.com/KeysetTS/scaffolding
Ruby ★ 17 18y agoExplain → -
request_profiler
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core. Request profiler based on integration test scripts
Ruby ★ 17 17y agoExplain → -
rails_fast_attributes
Experimental project
Rust ★ 16 7y agoExplain → -
rails-bot ⑂ ▣
Github hooks to provide an encouraging atmosphere for new contributors
Python ★ 13 7y agoExplain → -
tzinfo_timezone
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 13 18y agoExplain → -
localization
NOTICE: official repository moved to https://github.com/malev/localization
Ruby ★ 12 18y agoExplain → -
rails-probot
No description.
JavaScript ★ 9 2y agoExplain → -
tztime
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 8 18y agoExplain → -
rails-deprecated_sanitizer ⑂
Deprecated sanitizer API extracted from Action View.
Ruby ★ 8 2y agoExplain → -
discourse-rubyonrails-theme
No description.
SCSS ★ 7 2y agoExplain → -
continuous_builder
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 7 18y agoExplain → -
rails-master-hook
No description.
Ruby ★ 5 3mo agoExplain → -
gem-buildkite-config
No description.
Ruby ★ 4 2y agoExplain → -
hide_action
NOTICE: official repository moved to https://github.com/sikachu/hide_action
Ruby ★ 4 16y agoExplain → -
sqlite2_adapter ▣
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
Ruby ★ 3 17y agoExplain → -
fcgi_handler
WARNING: this repo is not maintained anymore, if you want to maintain it, please send an mail to rails-core
★ 3 17y agoExplain → -
rdoc ⑂
RDoc produces HTML and online documentation for Ruby projects.
Ruby ★ 2 2y agoExplain →
No repos match these filters.