Stack Engineer

Install Jekyll on macOS

Whether you're using Jekyll to build your own blog, static site, or using it as part of a development environment, you can get it up and running on your macOS system in four simple steps. You'll be running all of these commands from the terminal. Be sure to check out the Jekyll Quick-start Guide and review the additional commands below after installation.

Step 1 - Install the Xcode Command Line Tools Package

You'll need to install command line tools so you can develop from the terminal. During setup a software update box may popup. You don't need to get the full Xcode application, you can just need to install the tools.

xcode-select --install

Step 2 - Install Homebrew

Installing Homebrew will allow you to easily install other packages.

/usr/bin/ruby -e "$(curl -fsSL"

Step 3 - Install Ruby

macOS already comes preloaded with an old version of Ruby, but this will install the latest release.

brew install ruby

Step 4 - Install Jekyll and Bundler

And lastly, it's time to actually install the Bundler and Jekyll gems.

sudo gem install bundler
sudo gem install jekyll

Additional Commands

The first step is to create a new Jekyll site.

jekyll new sitename

Test the site using the built-in development server, then point your browser to http://localhost:4000.

cd sitename
jekyll serve

Build your static site into the _site subdirectory.

jekyll build

Remember to update installed packages from time to time.

brew update
sudo gem update