× press ESC to close

Migrating your Jekyll site to Netlify

Brian Douglas posted this on May 11, 2017

This post will cover how to move your Jekyll site from GitHub Pages to Netlify in with just a few steps.

If you have generated your Jekyll site using GitHub pages or forked a template there is a good chance you do not have a Gemfile. This is because GitHub pages will infer dependencies for you. If you would like to build your project outside of GitHub a Gemfile is needed and simple to create.

In your GitHub repo create a new file with the name Gemfile and add the following content to it:

source "https://rubygems.org"

gem 'jekyll', '~> 3.4.0'

Once you have a Gemfile you can now connect your site to Netlify without issue.

Adding a new site with Git is not a requirement for adding a site, but it’s strongly recommend to take advantage of all of Netlify’s continuous deployment features.


Once your site is connected, you can find your Repository from the list GitHub repos. There is also a convenient search box in case you have more repositories than the page can fit.


Finally, you will just need to add the Jekyll build command and build location. For Jekyll that is jekyll build for the command and _site for the location.


You now have your Jekyll site on Netlify and can take advantage of some great features, like deploy previews and free custom domains with SSL.

If you made it this far and do not have a Jekyll site to try this out with, you can try out my Jekyll template.

Notice something is incorrect or outdated?

First off, great eye! We appreciate your discovery and want to ensure it gets addressed immediately. Please email us at support@netlify.com.

About Netlify

Netlify is an all-in-one platform for deploying and automating modern web projects.

Simply push and Netlify provides everything—servers, CDN, continuous delivery, HTTPS, staging environments, prerendering, asset post processing, DNS, and more.

Any project, big or small, can perform instantly on a global scale.

Don’t let your site be slow and vulnerable.