# Custom Jekyll theme without Gems

**URL:** <https://talk.jekyllrb.com/t/custom-jekyll-theme-without-gems/4815>\
**Category:** Uncategorized\
**Created:** [August 5, 2020, 3:36pm UTC](https://talk.jekyllrb.com/t/custom-jekyll-theme-without-gems/4815 "2020-08-05T15:36:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![caolin](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/caolin/32/1261_2.png) [@caolin](https://talk.jekyllrb.com/u/caolin)\
**Post date:** [August 5, 2020, 3:36pm UTC](https://talk.jekyllrb.com/t/custom-jekyll-theme-without-gems/4815/1 "2020-08-05T15:36:21Z")

</div>

I am at a complete loss to understand how to create a Jekyll theme that can be used both locally and on GitHub Pages. As I understand it, I should not use themes packaged in Gems as GitHub places restrictions on these but when I try to create and use a standalone theme, Jekyll seems to insist on a default theme if none is specified. I have been unable to find a way of packaging my theme without using Gems so that it can be picked up by Jekyll. I am running the latest version of Jekyll locally on Ubuntu 20.04 in preparation for deploying my site to GitHub when everything is ready.

---

<div class="post-metadata">

**Author:** ![michaelbach](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/michaelbach/32/2151_2.png) [@michaelbach](https://talk.jekyllrb.com/u/michaelbach)\
**Post date:** [August 6, 2020, 5:49am UTC](https://talk.jekyllrb.com/t/custom-jekyll-theme-without-gems/4815/2 "2020-08-06T05:49:29Z")

</div>

I’m not sure if I understand you correctly, but you can use Jekyll completely without a theme. Everything can also directly be specified in `_config.yml`, CSS/SCSS files and layouts. That’s how I run my site with \>200 pages and very different sections. Best, Michael

---

<div class="post-metadata">

**Author:** ![ashmaroli](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@ashmaroli](https://talk.jekyllrb.com/u/ashmaroli)\
**Post date:** [August 6, 2020, 2:14pm UTC](https://talk.jekyllrb.com/t/custom-jekyll-theme-without-gems/4815/3 "2020-08-06T14:14:51Z")

</div>

@caolin The procedure is very simple when you know what you want.  
To re-iterate your use-case, you desire to:

- develop a jekyll theme that is usable locally and on GitHub Pages
- not package the theme as a Rubygem.

There are two ways to accomplish this:

- classic Jekyll site — the theme and site source files co-exist in **the same repository**
- remote-theme — the theme and site source files are in **two separate repositories**

The _classic_ way was how Jekyll sites got built by default prior to theme-gem support. You can still follow this structure as it easier to maintain as layouts and Markdown files are at same place…

With the _remote-theme_ way, you use a plugin named `jekyll-remote-theme` and link your site’s repository to **a public theme repository hosted on GitHub**. The advantage of this route is that your site contents are just your Markdown files.

* * *

Regarding the issue you are facing, you can only use the config key `theme` for a Ruby gem.  
When using the remote-theme plugin, you use the config key `remote_theme` instead. Details can be found at: [https://github.com/benbalter/jekyll-remote-theme#declaring-your-theme](https://github.com/benbalter/jekyll-remote-theme#declaring-your-theme)
