What Rails Does
- MVC — Model, View, Controller architecture
- ActiveRecord — ORM with migrations, validations, associations
- Scaffold — one-command CRUD generation
- Routing — RESTful resource routing
- Action View — ERB/Haml templates
- Action Cable — WebSocket framework
- Active Job — background job abstraction
- Action Mailer — email sending with templates
- Active Storage — file uploads to S3/GCS/Azure
- Turbo + Stimulus — Hotwire for HTML-over-the-wire
- Kamal — deploy Rails anywhere with Docker
- Solid Queue/Cache/Cable — database-backed infrastructure
Architecture
Full MVC with an opinionated project structure. Convention over Configuration means file names, directory layouts, and naming patterns determine behavior. Asset pipeline (Propshaft/Dartsass in Rails 7+) for CSS/JS. Rails 8 introduces Solid trifecta for database-backed queues, caches, and WebSockets.
Self-Hosting
# Production (Rails 8)
KAMAL_REGISTRY_PASSWORD=xxx kamal setup
kamal deploy
# Traditional
bundle exec puma -C config/puma.rb
# Behind Nginx reverse proxyKey Features
- Convention over Configuration
- ActiveRecord ORM
- Scaffold generators
- RESTful routing
- Hotwire (Turbo + Stimulus)
- Action Cable (WebSocket)
- Active Job (background)
- Active Storage (uploads)
- Kamal deployer
- Rails 8 Solid trifecta
- Mature gem ecosystem
Comparison
| Framework | Language | Philosophy | Speed |
|---|---|---|---|
| Rails | Ruby | Convention > config | OK |
| Django | Python | Batteries-included | OK |
| Laravel | PHP | Elegant syntax | OK |
| Phoenix | Elixir | Convention + speed | Fast |
| Spring Boot | Java | Enterprise auto-config | OK |
| Next.js | TypeScript | Full-stack React | Fast |
FAQ
Q: Rails performance? A: Ruby 3.3 + YJIT makes Rails 3x faster than Ruby 2.x. Shopify runs a million global merchants on Rails. Performance bottlenecks are usually in the database, not the framework.
Q: Rails 7 vs 8? A: Rails 8 introduces Solid Queue (DB-backed queue, no Redis needed), Solid Cache, and Solid Cable, simplifying deployment. Combined with the Kamal deployer, the goal is that even solo full-stack developers can deploy anywhere.
Q: What is Hotwire? A: Turbo (HTML-over-the-wire, replacing SPAs) + Stimulus (lightweight JS sprinkles) + Strada (mobile bridge). Use Rails to build full-stack apps without React or a frontend/backend split.
Sources
- Docs: https://guides.rubyonrails.org
- GitHub: https://github.com/rails/rails
- License: MIT