# Configure Magento with Square - Sandbox Mode

Go to the Square App you have created from your Square Account. Select Sandbox from the top and then select Credentials from the left sidebar.

You will get a Sandbox Application ID and Sandbox Access Token.

![Square Application ID and Access Token Sandbox Mode Square Payment](https://magecomp.com/support/wp-content/uploads/2023/05/Square-Application-ID-and-Access-Token-Sandbox-Mode-Square-Payment.png)

Now head on to your Magento store admin. Go to Stores > Configuration. Under the MageComp tab, select the Squareup tab. Expand the General Configuration option.

<figure><img src="/files/kyviKAU4V9F3saXf6qII" alt=""><figcaption></figcaption></figure>

* Application Mode – Select the Sandbox option for testing payments through Square.
* Sandbox Application ID – Copy the Sandbox Application ID from the Square account and paste it here.
* Sandbox Access Token – Copy the Sandbox Access Token from the Square account and paste it here.

Click on the Save Config button.

Now, expand the Oauth Configuration option.

<img src="https://magecomp.com/support/wp-content/uploads/2023/05/Oauth-Configuration-Sandbox-Mode.png" alt="Oauth Configuration Sandbox Mode" height="205" width="916">

* Get Sandbox Location – Click the Get OAuth Token button to retrieve the location.
* Sandbox Location – Select the location from the dropdown.

Again hit the Save Config button to apply your configuration settings.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.magecomp.com/magento-2-square-payment-gateway-extension/configure-magento-with-square-sandbox-mode.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
