Using sandboxes

You can use Sandboxes in the Developer area to create and manage your sandboxes in the studio.

311cb1a Click sandboxes in the developer area

Once open, you'll see any sandboxes you've already created first, followed by the sandboxes that've been created by others in your project (by default this is collapsed).

5a48ab7 Sandbox management

Use the search to look for a particular sandbox (it's based on the name of the sandbox).

889bcc1 Use search to search for a sandbox label

For how to work with sandboxes, see the sandboxes article.

Creating a sandbox

To create a sandbox, follow the steps below.

  1. Click the Add schema button

f186074 Click add sandbox to add new sandbox

  1. Input a Label (must only contain lowercase letters, numbers, and dashes)

5985274 Sandbox label

  1. Input the Branch which has the desired backend features you want to work on (it'll default to your master branch if left empty)

222dbf9 Input a branch

The Add public DNS option is automatically selected. You can't disable this.

  1. Click Create

f38d7ed Click create

Your sandbox will then be brought up. This will take less than 10 minutes.

Halting a sandbox

Once you've finished working, you can Halt or Destroy your sandbox using the corresponding buttons:

95bdb6b Halting or destroying a sandbox

If you halt your sandbox, you can bring it up again when you want to by clicking the Bring up button:

d5bf09a Bring up a halted sandbox

You should regularly destroy your sandbox and then create a new one. It's actually a good idea to destroy the sandbox when you finish work and create a new one the next day to avoid issues.

Public sandbox

All sandboxes are created with public DNS enabled. This allows you to access the projects running on the sandbox directly from any web browser without the need for local developer tooling, such as CLI. This can be useful to:

  • Show a certain feature (which only exists in a branch) to non-technical users
  • Work with code that strictly requires HTTPS connection (such as payment extensions)
  • Preview a certain production build without deploying it to your staging environment
  • Run automated tests towards a certain state of your code

Once a sandbox is running, you can click the See public URLs button to access the list of URLs for your sandbox.

79f473b Click see public urls

You can then click the open icon to open the URL. Or the copy icon to copy the URL for you to share with your team.

e6dd4fb Click the copy button or the open link

Sandbox statuses

There are 5 statuses a sandbox can have:

  • Transient — the sandbox is being brought up, you can't use it for development yet
  • Running — everything is working normally and you can use this sandbox for your development
  • Halted — someone has pressed the Halt button, you can only use this sandbox if you press the Bring up button
  • Debuggable — the sandbox has errored and you can't use this sandbox for development, but you can use it to find out why it errored
  • Errored — the sandbox has fatally errored and you can't use this sandbox at all

For both the Debuggable and Errored states, you'll see a bug icon like the below:

9f7a7ea Debuggable

If you click this icon, you'll open the logs where you can look into the components that failed to initialize. The failed components should already be expanded, or you can use the + icon to expand a component section and look into the issues.

3c0433d Error log

Sandbox notifications

We recommend destroying your sandbox once you've finished work for the day. And then bring up a new one the next day. This is because out-of-date sandboxes can cause a lot of issues. Because of this, you'll see a warning notification when your sandbox is more than 3 days old:

6568628 Outdates sandbox notification

You can continue working on this sandbox if you want to, but if you run into any errors, you should destroy the sandbox and create a new one to see if the issue still occurs.