Documentation
Getting Started
Open source collaboration

Open Source Collaboration

Working with your favorite Open Source repositories is easier with CodeSandbox. Whether you are just checking out a repository, testing out an idea or formally proposing a feature, CodeSandbox OS can eliminate tedious steps in your process and get you working on your ideas faster.

Viewing Open Source repositories

Explore any open source repository through CodeSandbox simply by adding the repository's GitHub URL to the end of the codesandbox URL, in the format below:

codesandbox.io/p/ github/[org]/[reponame]

For example, try codesandbox.io/p/github/codesandbox/sandpack/.

Forking Open Source Repositories

Traditionally, contributing to an open source repository happens through forking. You can fork an open source repository by opening it in the editor, clicking in the Branch dropdown in top right corner in the editor and selecting the Fork project option.

Fork from editor

You can also create a fork by importing the repository using the New project button in the team page. If you try to import a repository you don't have write access to, CodeSandbox will automatically create a new fork in the GitHub organization of your preference.

Create New Fork

By default, when opening a PR from a forked repository, it will point to the main branch of your repository. If you would like to target the parent repository, you can do so through the GitHub PR UI.

Introducing Contribution Branches

Easier and faster than forking repositories, contribution branches allow you to interact with code and open PRs without the need to import or create a project.

Contribution Branch

Contribution branches are standalone branches designed to simplify the contributing process. PRs created from them will always target the parent repository, showing up in the maintainers' list like any regular PR.

To create a contribution branch, open the repository in the editor and click on the Branch button in top right corner. By default, the option New contribution branch will be selected.

Crate a Contribution Branch

If you try to import a repository you don't have write permission to, a new fork will be automatically created. However, during the import process you can select the option to Create a Contribution Branch to start working immediately.

Your contribution branches are acessible anytime through the Personal projects section in the Projects Dashboard.