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

# BigQuery Integration

> Connect Isofold to BigQuery and start saving instantly.

## Connect Isofold to BigQuery

BigQuery is fully supported by Isofold, including native cost estimation via dry-run mode. You can use Isofold with the `bq` CLI, client libraries, or REST API.

***

## CLI Integration

Update the `--api_endpoint` flag to route your queries through Isofold.

```bash theme={null}
bq query \
  --project_id=myproject \
  --use_legacy_sql=false \
  --api_endpoint=https://proxy.isofold.com \
  'SELECT * FROM dataset.table'
```

Use your team’s assigned Isofold proxy URL, such as:

```text theme={null}
https://myteam.proxy.isofold.com
```

***

## Client Library (Node.js)

Configure the BigQuery client with the `apiEndpoint` option:

```ts theme={null}
import { BigQuery } from '@google-cloud/bigquery'

const bq = new BigQuery({
  projectId: 'myproject',
  apiEndpoint: 'https://myteam.proxy.isofold.com'
})
```

***

## Client Library (Python)

Set the `client_options` with the proxy endpoint:

```python theme={null}
from google.cloud import bigquery
from google.api_core.client_options import ClientOptions

client = bigquery.Client(
  client_options=ClientOptions(
    api_endpoint="https://myteam.proxy.isofold.com"
  )
)
```

***

## Cost Estimation & Verification

Isofold supports:

* **Dry-run optimization** using BigQuery’s native cost analysis
* **Verification mode**, where both the original and optimized query are run and compared for output equivalence

Enable verification via environment variable:

```bash theme={null}
export ISOFOLD_VERIFY_MODE=true
```

***

## Monitoring Query Savings

After integration, head to your Isofold dashboard to:

* View query rewrites and diffs
* Analyze cost savings vs baseline
* Monitor optimization coverage

***

Need to run Isofold in your own VPC? See the [self-hosted setup](/setup/self-hosted).
