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

# Lottery

> Buy tickets for a growing jackpot, withdraw within 10 minutes, and win stake-proportional.

# Lottery

> Buy tickets for a growing jackpot, withdraw within 10 minutes, and win stake-proportional.

## Overview

The lottery is a shared jackpot that grows as players buy tickets. **Every transfer fee** from `;pay` also flows into the active lottery jackpot, so it grows passively even without direct ticket sales.

When a lottery ends, one winner is drawn. Your chance of winning is **proportional to how much you've spent** — not just how many tickets you hold.

<Frame caption="Active lottery">
  <img src="https://cdn.raze.lat/cdn/1117553916075331656/1777890945-363894.png?v=1777890945" alt="Lottery overview" />
</Frame>

***

## Viewing lotteries

<Tabs>
  <Tab title="Syntax">
    ```bash theme={null} theme={null}
    ;lottery
    ```

    Opens a paginator showing all active lotteries. Each page shows the current jackpot, your paid-in amount, your win percentage, participant count, tier prices, and time remaining.
  </Tab>

  <Tab title="Example">
    ```bash theme={null} theme={null}
    ;lottery
    ```

    Opens a paginator showing all active lotteries. Each page shows the current jackpot, your paid-in amount, your win percentage, participant count, tier prices, and time remaining.
  </Tab>
</Tabs>

***

## Buying tickets

Click **Buy Tickets** in the lottery browser to open the purchase modal. Choose your tier and quantity (1–100).

**Ticket pricing:**

Ticket prices are not fixed — they scale upward as the jackpot grows:

```
tier_price = base_price × (1 + jackpot / $500,000)
```

A $10,000 base-price ticket in a $1M jackpot will cost \$30,000. This keeps the lottery economy balanced.

**Lottery luck boost:**

If you have an active **Lottery Luck** boost from the shop, buying tickets grants bonus free tickets on top of your purchase at no extra cost.

***

## Refunding tickets

You have a **10-minute window** after purchasing tickets to request a full refund.

After buying, you'll receive a DM from the bot with a **Withdraw** button. Click it within the window to get your full amount back. The jackpot is reduced accordingly. The withdraw button also appears in the lottery browser.

<Warning>
  Once the 10-minute window closes, tickets cannot be refunded. Plan your purchases accordingly.
</Warning>

***

## Winning

When a lottery ends, a single winner is drawn using **stake-proportional weighting**:

* Spending more = proportionally higher win chance
* There is no one-ticket-one-entry system — total amount spent determines your probability

The winner receives the entire jackpot. A winner announcement is sent to the channel where the lottery was started.

***

## Auto-cycle

If no lottery is active and **3 days** have passed since the last lottery ended, the bot automatically starts a new 24-hour global lottery with default tiers. The economy never goes without a lottery for long.

***

## Lottery info

<Tabs>
  <Tab title="Syntax">
    ```bash theme={null} theme={null}
    ;lottery info lottery_id
    ```

    View detailed information about any lottery — active or historical. Past lotteries show the winner, final jackpot size, and timestamps.
  </Tab>

  <Tab title="Example">
    ```bash theme={null} theme={null}
    ;lottery info 7
    ```

    View detailed information about any lottery — active or historical. Past lotteries show the winner, final jackpot size, and timestamps.
  </Tab>
</Tabs>

***
