An organization-level website to allow URL redirects when our repositories have been renamed or moved.


Adapted from

The problem

We have a repository, e.g. inbo/repo. We would like to rename it to inbo/repo-new or transfer it to the organization trias-project, so it will become trias-project/repo.

However, we make heavy use of the GitHub Pages feature for that repository, so that people are often accessing GitHub will helpfully redirect all of our repository stuff hosted on after the move, but will not redirect the GitHub Pages hosted on

The solution

We solve this by having this inbo/ repository, which creates an organization-level GitHub Pages website. We now can:

  1. Rename or transfer the repository, thus breaking all the links
  2. Add a file repo/index.html to this repository, which uses <meta http-equiv="refresh"> to redirect to the new URL. The index.html file should look like this (also documented in the rOpenSci devguide):

         <meta http-equiv="refresh" content="0;URL=">

Once done, will still exists as a working URL, even though the inbo/repo repository does not. And it will redirect to the new URL.