# Hide tables from AI clients

> Hide staging copies, backups, and other tables from what agents find on a data source, while a query that names one continues to run.

Updated: 2026-11-09

Bonnard removes a hidden table from what agents find on that data source.

> [!WARNING]
> If you hide a table, an agent can continue to read it. An agent that names it in SQL, for example
> `SELECT * FROM <table>`, gets the rows if the credential that Bonnard connects with can read the table. To stop that,
> remove the table from the credential's grants, as in
> [the PostgreSQL guide](https://bonnard.ai/docs/connect-data/postgresql.md#1-create-a-read-only-user).

## Requirements

- The Editor role or higher in your workspace.
- To work from your AI client: [Bonnard connected](https://bonnard.ai/docs/ai-clients/connect-your-ai-client.md) and access to the data source.

## Hide a table

After you publish the draft, agents cannot list the table, find it in a search, or get its columns by name. Metrics that
name it are withheld. Draft with AI in the dashboard editor is the exception: it continues to find it.

### In your AI client

Ask:

```prompt
In <data source>, hide the <table> table from AI clients.
```

Then [publish the draft](https://bonnard.ai/docs/context/review-and-publish.md#publish).

### In the console

1. In the console at `app.bonnard.ai`, select **Context**. With more than one data source, select one at the top right.
2. Select **Tables**.
3. Set the **Visible** switch in the table's row to off.
4. [Publish the draft](https://bonnard.ai/docs/context/review-and-publish.md#publish).

[Image: The Tables list in Context: All, Visible, and Hidden filters above four tables, each with a Visible switch set to on]

## Show it again

A table hidden on an old app, before 2026-10-27, stays hidden from agents even when Context shows it as visible. To clear
it, [get in touch](https://bonnard.ai/get-in-touch).

### In your AI client

Ask:

```prompt
In <data source>, show the <table> table to AI clients again.
```

Then [publish the draft](https://bonnard.ai/docs/context/review-and-publish.md#publish).

### In the console

1. In the console, select **Context**, then **Tables**, then **Hidden**.
2. Set the **Visible** switch in the table's row to on.
3. [Publish the draft](https://bonnard.ai/docs/context/review-and-publish.md#publish).

## Make sure that the table is hidden

After you publish, ask your AI client:

```prompt
Describe the <table> table in <data source>.
```

The agent's lookup is refused with `Table '<table>' not found or hidden from AI clients.`

In the console, select **Context**, **Tables**, then **Hidden**. The table is in the list, and its page has the badge
Hidden from AI clients.

## Related

- [Publish context changes](https://bonnard.ai/docs/context/review-and-publish.md): review the draft and take it live.
- [Give access to data](https://bonnard.ai/docs/access/give-access.md): decide who can use the data source at all.
- [PostgreSQL](https://bonnard.ai/docs/connect-data/postgresql.md#1-create-a-read-only-user): give a read-only user grants on only the
  tables you want it to read.
