Skip to main content
Sharing Sandbox Programs

Embed, share, and fork programs created in the CodeHS Sandbox and IDE

Jeremy Keeshin avatar
Written by Jeremy Keeshin
Updated over 6 months ago

Sharing Sandbox Programs and Code

  • Teachers’ Sandbox programs are automatically shared. Any program a teacher creates in Sandbox is automatically public. Anyone can visit the URL of a Sandbox program and see it in the editor.

  • Visiting the URL of a Sandbox program will take you to the IDE so you can see the output side-by-side with the code, mess around and make some changes, and even fork the program to your own sandbox.

  • Logged-out users can also create shared programs in the sandbox and send them to their friends or teacher.

  • If you'd like to exclusively share the output, like before, you can turn off "Show Code" in your share settings:

Screenshot highlighting the Share button at the top right of the code editor.

Screenshot of the popup window that generates a shareable URL

If your students are not able to use email to share links with each other, you can use this sheet to collect and distribute links for your class. Just make a copy in your own Google Drive and use the sheet to share student links.

Embedding Sandbox Programs

Sandbox Programs also have an embed link which are used to embed them in a webpage. The “Embed” link is the URL for your shared program with “/embed” at the end.

Screenshot of the Embed tab that generates HTML code you can paste onto a website

Fork Sandbox Programs

Forking is the ability to copy a program to your own sandbox, essentially taking a snapshot of it and making it your own.

  • Go to the shared link of any Sandbox program

  • Hit the Fork button to create a separate copy of the code in your Sandbox.

  • Making and saving changes to this copy won't affect the original program.

Screenshot highlighting the Fork button at the top of a Sandbox program

Video Demos

Sharing Sandbox Programs

Forking Sandbox Programs

CodeHS Tutorial

Our team created a tutorial to show how you can use the CodeHS Graphics JavaScript library outside of CodeHS on any website. Check it out here:


Still have questions? Contact our team at hello@codehs.com to learn more!

Did this answer your question?