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

# Make your first variable

> Make a coins variable, step by step.

In this guide we make a variable called **coins**. Every member of your server will have their own coins, and everyone starts with **0**.

You can make a variable in **two places**. Both make exactly the same thing, so pick the one you like.

## Way 1: on the Database page

<Steps>
  <Step title="Open the Database page">
    Press **Database** in the sidebar.
  </Step>

  <Step title="Start a new variable">
    Open the **Start from scratch** tab.

    <Info>
      In a hurry? The **What do you want to make?** tab has ready-made ideas. Pick one and DogeBot makes it for you, then shows the new `{DBVAR_...}` names you can use.
    </Info>
  </Step>

  <Step title="Give it a name">
    Type `coins`.

    Good names are short and tell you what is inside. Use small letters. If you use spaces or dashes, DogeBot turns them into `_`, so `daily reward` becomes `daily_reward`.
  </Step>

  <Step title="Pick the type">
    We want every member to have **their own** coins, so pick **User**.

    Then DogeBot asks **what each member stores**. Coins are a number, so pick **Number**.

    <Info>
      Not sure which type to pick? Read [Types of variables](/variables/types-of-variables). The short version: **User** means "every person has their own".
    </Info>
  </Step>

  <Step title="Pick the scope">
    Pick **Server Specific** if each Discord server should have its own coins. Pick **Global** if a member's coins should be the same in every server your bot is in. Most people pick **Server Specific**. See [Server or Global](/variables/server-or-global).
  </Step>

  <Step title="Give it a starting value">
    Type `0`. Every new member starts with 0 coins.
  </Step>

  <Step title="Save">
    Press the button to create it. You see **Variable Created**: `{DBVAR_coins}` is ready to use in your commands and events.
  </Step>
</Steps>

## Way 2: inside the builder

This is handy when you are in the middle of building a command and notice you need a new box.

<Steps>
  <Step title="Open the Variables panel">
    In the builder, look at the thin bar on the far left. Press **Variables**.
  </Step>

  <Step title="Create a new one">
    Press **Create New Variable**. A window opens with the same choices as the Database page: name, type, scope and starting value.
  </Step>

  <Step title="Save it">
    Press **Add Custom Variable**. The new variable shows in the list with its `{DBVAR_...}` name and its starting value.
  </Step>
</Steps>

<Check>
  Variables made in the builder are saved in the same place as the Database page, so you always see them in both places.
</Check>

## Now use it!

Your box is ready, and it holds 0. Next:

1. [Show it in a message](/variables/show-a-variable-in-a-message), like `You have {DBVAR_coins} coins`.
2. [Change it with a block](/variables/change-a-variable-with-blocks), like "add 100 coins".

Want to see a whole working coins system? Follow the [Economy](/build-a-system/economy) recipe.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.