Skip to main content

Notebook.link now supports GitLab

· 4 min read
QuantStack
Scientific Software Computing

Your GitLab notebooks, just a prefix away​

Notebook.link and GitLabNotebook.link and GitLab

Since launch, Notebook.link has let you turn a GitHub repository into a live, runnable Jupyter environment with a single link. But a lot of scientific and teaching material doesn't live on GitHub: universities, research labs and open-source communities host plenty of it on GitLab.

Starting today, GitLab is a first-class Git provider on Notebook.link. Any public repository on gitlab.com can be opened, run and shared the same way as a GitHub repository, with the same environment handling, lock files and interface styles.

Open a repository from its URL​

The fastest way to try it doesn't even need the dashboard. Take the URL of a GitLab project and put notebook.link/ in front of it:

https://gitlab.com/{group}/{project}
↓
https://notebook.link/gitlab.com/{group}/{project}

Notebook.link redirects you to the canonical form of the link, https://notebook.link/gitlab/{group}/{project}/, downloads the repository, sets up its environment and opens it in JupyterLite, all in your browser.

Without a git reference, the link follows the latest commit of the default branch. Links follow GitLab's own URL structure, so you can copy a path from the GitLab interface and it just works:

ReferenceLink
Default branchhttps://notebook.link/gitlab/{group}/{project}/
Nested groupshttps://notebook.link/gitlab/{group}/{subgroup}/{project}/
Branchhttps://notebook.link/gitlab/{group}/{project}/-/tree/{branch}/
Commithttps://notebook.link/gitlab/{group}/{project}/-/commit/{sha}/
Taghttps://notebook.link/gitlab/{group}/{project}/-/tags/{tag}/
Merge requesthttps://notebook.link/gitlab/{group}/{project}/-/merge_requests/{number}/

Two GitLab habits are supported from day one:

  • Nested groups: projects can sit arbitrarily deep, e.g. my-university/physics/lab-2026/tutorials.
  • Branch names with slashes, such as feature/new-exercises.

The New Link form on the Link page now asks which Git provider hosts your repository. Pick GitLab, paste the project path (or the full https://gitlab.com/... URL, which is cleaned up for you), and choose what to snapshot: a commit, a branch, a tag or a merge request.

Everything else works as it does for GitHub links. You can give the link a name and an alias (https://notebook.link/@{username}/{alias}), choose the file opened by default, pick the Windowed, Single-document or Presentation interface, and make the link public or unlisted.

Your repository, your environment​

GitLab repositories are prepared for Notebook.link exactly like GitHub ones. You don't need GitLab-specific configuration:

  • Describe the environment in an environment.yml at the repository root or in .nblink/.
  • Commit a nblink-lock.json lock file to pin package versions, so your link keeps working years from now.
  • Optionally add a jupyter-lite.json to customize the JupyterLite runtime.

If your repository is already Notebook.link ready on GitHub, a GitLab mirror of it is ready too. See Prepare your Git repository for Notebook.link for the details.

After you push new commits​

As with GitHub, the git reference you choose decides what your audience sees after you push:

  • A branch, a merge request or no reference always shows the latest commit.
  • A tag or a commit hash is a fixed snapshot.

When a link needs to show the exact same content and environment for years, as course material or a paper's companion notebooks usually do, use a commit hash together with a lock file.

Branches, tags and merge requests are resolved to a commit through the GitLab API. If you ever hit its rate limit, a commit link still works, since it doesn't query the API.

Current limitations​

This first release focuses on the most common case. Some things aren't supported yet:

  • Public repositories only. Private GitLab projects can't be opened yet. Private GitHub repositories work through the Notebook.link GitHub app, but GitLab has no equivalent yet.
  • gitlab.com only. Self-hosted GitLab instances aren't supported yet.
  • The 50MB repository size limit applies, as it does for GitHub.

Try it​

Pick your favorite notebook repository on gitlab.com, put notebook.link/ in front of its URL, and see it run in your browser. If something doesn't work as expected, or you need to connect notebook.link to a private GitLab instance, let us know.