Getting started
Code Harbor is a collection of browser games, plus repositories you can open, read and preview. Here is how to use both.
1. Open a project
- Go to the Repositories page. Until the first real repository is created, it shows a sample project.
- Type in the Search repositories box at the top to find a repository by owner or name, then choose it from the results.
- If more than one repository exists, use the switcher beside the branch name to move between them.
2. Browse files
- The Files tab lists each file with its last commit and when it was updated.
- Select a file to read its contents. Without a file selected, the README.md is shown below the list.
- Signed-in owners can add files to their own repository with Add file. Anyone else can browse without signing in.
3. Use the preview
- Open the Preview tab, or use the Preview panel in the side column.
- A preview runs as a static site from the repository's index.html. If there is no index.html, the page tells you the preview cannot run.
- Previews are shown in a locked-down frame that does not run scripts.
Play and create games
- Open Games to browse the collection. Pick a game made by a creator and play it in the browser, no account needed.
- Sign in with Google, open Create a game, and write your game in HTML, CSS and JavaScript. Save it to publish it with a link anyone can play.
- Games run in a locked frame with no access to your account. Link a game to one of your repositories to let its editors help you change it.