# Advanced - Custom Server for Metadata

{% hint style="info" %}
This option is advanced and requires you to host the metadata on your own website/server using a specific URL.
{% endhint %}

When creating your store, you have the option to host the metadata on your own servers.

You might want to do this because:

* You want to change the metadata periodically
* Your project requires the metadata to be changeable
* You want to control your data
* You want to host your metadata on another platform outside of Mintable

#### Requirements <a href="#requirements" id="requirements"></a>

**URL structure**

![](https://docs.mintable.app/~gitbook/image?url=https%3A%2F%2F4070683621-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-legacy-files%2Fo%2Fassets%252F-MBMfw1KGuBM0Z3DpPUt%252F-MNMDe3jFb1DHdZhIclP%252F-MNMN1ZufkPXWu_TZoSa%252Fb15bf865e78f603b09d3967d248cda7f.png%3Falt%3Dmedia%26token%3D8a2ae9e6-abe6-4c9c-95e7-454fbcf5e804\&width=768\&dpr=4\&quality=100\&sign=e4f2e94b\&sv=1)

**The BaseURI is stored on the contract and every token uses it for the URL**

Each token has a unique ID - such as token 1, token 2, token 3.

Each token will return a URL for the individual metadata of that token - so when you want the URL for token 3 - it will return: `baseURI + token ID`

If your baseURI is <https://mywebsite.com/metadata/> then token 3 will return:

`https://mywebsite.com/metadata/3`

This is important to note: your baseURI must have a "/" at the end

good: "<https://mywebsite.com/metadata/>"

bad (won't work): "<https://mywebsite.com/metadata>"

#### Hosting the data <a href="#hosting-the-data" id="hosting-the-data"></a>

Once you have set up the baseURI, you will need to host the data on your server according to that baseURI. So if you set your URL as above "<https://mywebsite.com/metadata/>" and you make the first 5 tokens, tokens 1 - 5, you will need to host the metadata for each token at:

| URL                                | TokenID |
| ---------------------------------- | ------- |
| <https://mywebsite.com/metadata/1> | 1       |
| <https://mywebsite.com/metadata/2> | 2       |
| <https://mywebsite.com/metadata/3> | 3       |
| <https://mywebsite.com/metadata/4> | 4       |
| <https://mywebsite.com/metadata/5> | 5       |

#### Creating the items <a href="#creating-the-items" id="creating-the-items"></a>

When you create a new item and list it for sale on the site - you will be shown the popup below. This will provide you the metadata you need to host on your server, in the format it should be hosted in.

You can change the "image:" field or any other field you'd like to change/add - but if you do - make sure you follow the NFT metadata standard

![](https://docs.mintable.app/~gitbook/image?url=https%3A%2F%2F4070683621-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-legacy-files%2Fo%2Fassets%252F-MBMfw1KGuBM0Z3DpPUt%252F-MNMDe3jFb1DHdZhIclP%252F-MNMPKqaPbSqc8WxXQzG%252F6d42b5cdb7ec14fce9fa2bc8abe65a8f.png%3Falt%3Dmedia%26token%3D0acfd23e-d8b0-4255-90a2-f3066c74c453\&width=768\&dpr=4\&quality=100\&sign=e624f091\&sv=1)

If you do not host this data at the <https://baseURI/tokenID> that you set - your token will not be displayed properly.

### Tokens not displaying properly <a href="#tokens-not-displaying-properly" id="tokens-not-displaying-properly"></a>

To debug the situation - go to etherscan.io and look up your contract's address.

Go to the "read" tab on Etherscan for your contract so you can read the smart contract.

Type in the token ID for the field "tokenURI()" on Etherscan.

![](https://docs.mintable.app/~gitbook/image?url=https%3A%2F%2F4070683621-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-legacy-files%2Fo%2Fassets%252F-MBMfw1KGuBM0Z3DpPUt%252F-MNMDe3jFb1DHdZhIclP%252F-MNMQ_gLTSkuR9zBBtBz%252Fdd24d6a3d9f021c2d87dabba4d20ab10.png%3Falt%3Dmedia%26token%3D6dbb8ac4-5c2c-4ec0-bcb2-477538a21172\&width=768\&dpr=4\&quality=100\&sign=4be0c818\&sv=1)

This is where your metadata needs to be located

The URL returned here is where the metadata for this token needs to be hosted. If your URL is incorrect, or you have another issue and cannot host your metadata here - then you won't be able to see/display this token.

The baseURI you set **must be correct**.


---

# 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.mintable.app/faqs/help/advanced-custom-server-for-metadata.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.
