In this blog post, we'll guide you through the process of installing a Drupal theme from a GitHub repository using Composer. We'll be using the Gesso theme as an example, which can be found at

Adding a Custom Repository to composer.json

To install the theme from GitHub, you'll need to edit your project's composer.json file by adding a new custom repository. Insert the following code block:

  "type": "package",
  "package": {
    "name": "forumone/gesso",
    "version": "2.0",
    "source": {
      "url": "",
      "type": "git",
      "reference": "8.x-2.x"

Add the code block after the following section in your composer.json file:

  "type": "composer",
  "url": ""

Next, run the following command to download the theme and update composer.lock:

composer require "forumone/gesso"

Alternative Installation from

Although installing the theme from GitHub is an option, it is important to note that the theme is also hosted on In most cases, you can simply install the theme using the following command:

composer require drupal/gesso

This method is recommended, as it ensures that you are installing a stable release of the theme.