Software⏱️ 2 min read📅 2026-05-31

How to Fix: SSL Error When installing rubygems, Unable to pull data from 'https://rubygems.org/

SSL certificate verify failed error when installing rails gem.

Quick Answer: Check your system's date and time to ensure it is set correctly, as the SSL verification fails due to an outdated or incorrect timestamp.

To resolve the SSL error when installing RubyGems, you need to update your system's OpenSSL version. This is because the default OpenSSL version may not be compatible with the newer HTTPS protocol used by RubyGems.

🔍 Why This Happens

  • [Cause]

🚀 How to Resolve This Issue

Method 1: Updating OpenSSL Version

  1. Step 1: Open a terminal and update the package list using your system's package manager. For example, on Ubuntu or Debian, run `sudo apt-get update`. On macOS with Homebrew, run `brew update

Method 2: Installing a newer version of OpenSSL

  1. Step 1: Install the latest version of OpenSSL using your system's package manager. For example, on Ubuntu or Debian, run `sudo apt-get install libssl-dev`. On macOS with Homebrew, run `brew install openssl

✨ Wrapping Up

After updating your OpenSSL version, try installing RubyGems again using the original command. If you still encounter issues, ensure that your system's date and time are correctly set.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions