27.06.2025

How to Install Ruby on Rails 3.1.2 on Windows – Step-by-Step Guide

A short note about the framework:

Ruby on Rails, often simply called Rails, is a powerful web application framework written in the Ruby programming language. Originally released in 2004 by David Heinemeier Hansson, it quickly gained traction due to its elegant design and developer-friendly principles, such as "Convention over Configuration" and "Don't Repeat Yourself" (DRY). A major milestone in its popularity came in 2006, when Apple announced that Ruby on Rails would be bundled with macOS 10.5 "Leopard", giving the framework broad exposure to developers worldwide.

One of the defining aspects of Rails is how it revolutionized web development by introducing a structured and automated approach to tasks like database table creation, schema migrations, and scaffolding. These features enabled rapid prototyping and streamlined the development of dynamic, database-driven web applications. Ruby on Rails also laid the foundation for modern full-stack frameworks by integrating routing, MVC architecture, and RESTful design principles—all of which continue to influence contemporary web technologies.

The uniqueness of Ruby

There are many web development frameworks in the programming world, but Django and Ruby on Rails stand out the most.

This makes them the most popular web development frameworks and this popularity will continue to grow.

Framework scalability

While Django inherited its scalability from Python, it is still slightly behind Rails. It has better scalability, which is a result of its qualities of freedom and code flexibility. Both are heavyweight web development frameworks, so they are both designed with scalability in mind, but in this case the win goes to Ruby on Rails.

Syntax

Ruby's syntax is known to be very flexible. However, this can not always be attributed to the advantages of Ruby on Rails. It can cause problems and make it difficult to pass a project to other team members, as the same function can be implemented in different ways, creating confusion.

Whereas Python advocates that there should only be one obvious way to do something, which makes the code easier to debug and read.

Installing the necessary packages:

To run Ruby on Rails on Windows 10, you need to install the following programs:

Let's move on to downloading and installing Nodejs.

Follow the link and download the LTS version.

After selecting the LTS version you will automatically start downloading the package, you need to install it by opening the executable file after downloading.

Required to select the automatic installation of the necessary tools.

After installation, restart your personal computer and go to the command line to check the installation.

Since we chose to install the necessary components, immediately after completion a script will open for installation.

You can check the installation by using the command :

node --version

Installing Yarn:

Follow the link, open the "Alternatives" tab and download the "classic stable 1.22.19" package.

Run the executable file and follow the installation steps.

After installation restart your PC and check the installation by running the command line and typing the command below:

yarn --version

Installing Sqlite:

Go to the link and download the two sqlite archives:

After downloading, unzip both archives to "C:\windows\system32"

You can check the functionality and version of sqlite using the command below:

sqlite3 --version

Installing Ruby:

Go to the link and download the latest version of Ruby with developer tools, currently "Ruby 3.1.2-1"

Install Ruby by opening the executable file. Also after installation is complete check the "run rdk install" option to install MSYS2 automatically.

The command line will automatically open with the offer to install MYSYS2, choose point 3.

Further installation is done automatically.

You can check Ruby version and availability using command below:

ruby --version

It's required to run the commands below, first opening a command line as admin:

gem install tzinfo-data
gem install sqlite3

gem install rails

Create a project and run Ruby on Rails:

Open a command prompt as an administrator. Navigate to the directory you want and type the command below:

rails new *project name*

After that, browse to your project directory and run your project with the command

rails server:

rails server

You can go to our server using your local address.

Note:

If you have a problem starting your project go to your project folder and open the Gem configuration file with any text editor you like. Fix the line as shown below:

Example error:

The line before the changes:

gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]

String after changes:

"gem tzinfo-data"

Use the commands below to check that all the packages you have installed are working:

Ruby --version
Sqlite3 --version
Node --version
Yarn --version
Gem --version
Rails --version

Conclusion:

Thanks to this step-by-step guide, you can easily install Ruby on Rails on a Windows 10 system without hassle. The tutorial walks you through every stage—from setting up Ruby and Rails dependencies to configuring the development environment—ensuring a smooth start for building web applications on Windows.