# Wallet Database

Query every active Solana wallet on 164 metrics with AND and OR groups, read the count, and save the result as a Data Import list. For the $250 plan.

The Wallet Database is every active wallet on Solana, queried directly\. You describe the wallet you want as conditions on the same 164 metrics Data Import shows, run the query, and get every wallet that matches as a Data Import list\. No bot commands, no files to upload\. Part of the Wallet Database \+ API plan; on the Plus plan the page shows a lock and a link to the plans\.

:::banner{type=info}
[Plans and what is included](/plans)
:::

```mermaid
flowchart LR
  A["Condition"] --> B["Group (AND / OR)"] --> C["Get Wallets"] --> D["Save as a Data Import list"]
```

## Build a query

Open **Wallet Database** in the sidebar\. The page is called **Wallet Database Search Builder**\. A query is one or more groups, and a group is one or more conditions; Group 1 is waiting for you with one empty condition\.

1. ### Write the first condition
   In the first row of Group 1, pick a metric in the first dropdown and an operator in the second, then type the value; the minus and plus next to it step the number\. The operators depend on the kind of metric:
   - **Numbers**: Equal, Not Equal, Greater Than, Less Than, Greater or Equal, Less or Equal, Between\.
   - **Dates**: Equal, Before, After, Between\. A calendar with a time picker opens for the value\.
   - **Text**: Equal, Not Equal, Contains, Starts With, Ends With\.
   Between asks for two values\.
2. ### Add conditions to the group
   Click the green plus in the group's header to add a condition\. Every condition inside a group is joined by the same word: **AND** means all of them must be true, **OR** means any one of them is enough\. One group, one word; you cannot mix the two inside a group\. The red cross removes the whole group\.
3. ### Add a group when you need to mix
   Click **Add Group**\. The new group carries an **AND / OR** switch in its corner that joins it to the groups above it, and has its own AND or OR inside\. Two levels is all there is: conditions inside groups, groups joined together\. That covers most questions; if you need more, split the query into two presets\.
4. ### Choose a limit and run
   In the **Limit** box next to **Get Wallets**, pick how many wallets you want back: 100, 500, 1,000, 5,000, 10,000, 50,000 or 100,000\. The default is 100,000\. Click **Get Wallets**\.

> [!TIP]
> A first query that works well, one group joined with AND: win rate over the last 7 days Greater or Equal 60, profit over the last 7 days Greater Than 5,000, average holding time over the last 7 days Between 10 minutes and 6 hours\. Then a second group, joined with OR, for the same numbers over the last 30 days\.

## Read the count and save the list

A window shows what the query found:

- **No results found\.** Loosen a condition and run again\.
- **Found N results**, with N at or under your limit\. Type a name for the list and click **Save**\. The wallets become a Data Import list and the list opens like any other: every metric a column, filters, presets, export\.
- **Found N results**, with N above your limit\. The window says the list will be built from the first wallets up to the limit and suggests narrowing the filters\. Save it as it is, or **Cancel**, tighten the query and run again\.

Each run saves a new list\. To keep a running database, export the list from Data Import and add it to another list with **Import Wallets**\.

## Save the query as a preset

Click **Presets** at the top right\. Type a name and click **Save as new**\. The preset joins the list; click it to load it, and the builder fills in every group and condition\. While a preset is loaded:

- Change something and an amber dot appears next to the name: unsaved changes\. Click **Update** to write them into the preset, or **Save as new** to keep both\.
- The trash icon, shown when you hover a preset, deletes it\.

> [!NOTE]
> The limit is not part of a preset; set it each time\. A preset is yours alone\.

> [!TIP]
> A preset per thesis, run every morning, is the fastest way to a fresh shortlist\. The Wallet Database is recomputed hourly, so the same query gives you today's wallets, not last week's\.

## Reuse the query in the API

**Reset**, at the top right, clears the builder\. **Query Preview**, under the builder, shows the query as JSON while you build it, with **Copy JSON**\. That JSON is exactly the body the [Wallet Database endpoint](/rest-wallet-database-query) of the REST API accepts: build and test a query here, paste it into your script, and the API returns the same wallets\.
