> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xano.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Sandbox Testing

## What is the Sandbox Environment?

For all paid plans as part of the [Xano CLI](xano-cli/get-started), the Sandbox Environment introduces ephemeral tenant environments as the structural safety layer for the code-first development workflow. By default, when you run the `workspace push` command, you will be blocked and prompted to first push to a sandbox environment.

`xano sandbox push` — push changes to your sandbox
`xano sandbox review` — edit any logic, inspect the snapshot diff, and promote changes to the workspace

The CLI spins up an isolated ephemeral environment and provides a link to you for review and validation before anything touches production.

## Using the Sandbox

<Tip>Make sure you've got the [Xano CLI](xano-cli/get-started) set up and authenticated before continuing. You'll also want to have some changes ready to preview and deploy, as that's when the sandbox is designed to be used.</Tip>

Push changes to your sandbox environment by running `xano sandbox push <directory>`, `<directory>` being the folder that contains your XanoScript.

After your changes have pushed to the sandbox successfully, run `xano sandbox preview` to open a preview of your changes in an ephemeral environment.

The environment is exactly the same experience you get working in Xano normally, but **read only**. You can browse the workspace, review data, run workflows, and anything else you'd like to do to test before pushing to your workspace.

The environments are only available for a limited time; you'll see a notification in the top-right corner giving you the opportunity to extend the time the sandbox is live if necessary.

<img src="https://mintcdn.com/xano-997cb9ee/GGKkNaTQIWPG92tN/images/sandbox-20260410-134529.png?fit=max&auto=format&n=GGKkNaTQIWPG92tN&q=85&s=5ab45a68809953f7b26561735d35e2c3" alt="sandbox-20260410-134529" width="537" height="190" data-path="images/sandbox-20260410-134529.png" />

If you run out of time and need to return, you;'ll also be able to do so by visiting the preview link again.

<img src="https://mintcdn.com/xano-997cb9ee/GGKkNaTQIWPG92tN/images/sandbox-20260410-134649.png?fit=max&auto=format&n=GGKkNaTQIWPG92tN&q=85&s=8fc21b0191fb12b35cb2f61c3c34ffd8" alt="sandbox-20260410-134649" width="595" height="503" data-path="images/sandbox-20260410-134649.png" />

When you've validated the changes present, click <span class="ui-bubble"><Icon icon="code-branch" /> Review & Push</span> button in the top-right corner. Choose the workspace to push to, and the branch to compare.

<img src="https://mintcdn.com/xano-997cb9ee/GGKkNaTQIWPG92tN/images/sandbox-20260410-134830.png?fit=max&auto=format&n=GGKkNaTQIWPG92tN&q=85&s=fa419fd18415dc7424ae9143110b29c8" alt="sandbox-20260410-134830" width="551" height="399" data-path="images/sandbox-20260410-134830.png" />

You'll be presented with a Git-style diff of all the changes being merged to your chosen branch / workspace.

<img src="https://mintcdn.com/xano-997cb9ee/GGKkNaTQIWPG92tN/images/sandbox-20260410-134913.png?fit=max&auto=format&n=GGKkNaTQIWPG92tN&q=85&s=0f1749c70a52fe33f414e912d5f96cec" alt="sandbox-20260410-134913" width="1893" height="960" data-path="images/sandbox-20260410-134913.png" />

When you're ready, click <span class="ui-bubble">Next</span>.

When merging changes, you'll always be merging them into a new branch. You'll be asked for a name to give to the new branch, and given the option to immediately set it live, if desired. When you're ready, click <span class="ui-bubble">Deploy</span>.

<img src="https://mintcdn.com/xano-997cb9ee/GGKkNaTQIWPG92tN/images/sandbox-20260410-135020.png?fit=max&auto=format&n=GGKkNaTQIWPG92tN&q=85&s=f858139c9e052f9acd4539eecbdefc53" alt="sandbox-20260410-135020" width="672" height="446" data-path="images/sandbox-20260410-135020.png" />

Once deployment finishes, you'll be taken back to your workspace with the new branch selected.
