---
title: "Connecting banks"
description: "Connect a new bank from the CLI through the web app, reauthenticate an existing connection, and search the institution catalog."
section: "CLI"
canonical: "https://banksync.io/docs/cli/connecting-banks"
---

Linking a bank means completing a provider flow (Plaid, Fiskil, SnapTrade, SaltEdge, and others), some of which are browser-mediated and need a real signed-in session. Rather than reimplement every provider handshake, the CLI hands off to the web app, which already implements them all, then waits for the result.

[![Connect a bank through the app](https://cdn.banksync.io/videos/connect-a-bank.poster.66e1177970490809.png)](https://cdn.banksync.io/videos/connect-a-bank.68a0b74986eed503.mp4)

[Watch: Connect a bank through the app](https://cdn.banksync.io/videos/connect-a-bank.68a0b74986eed503.mp4)

> **Connecting needs a browser and a web session:** banks connect opens an authenticated deep link into the BankSync web app. You need a browser and
> an active app session on the same machine. If you are logged out, the app returns you to the
> connect flow after sign-in. Headless environments cannot complete a connect; use --no-input to
> get the URL and open it elsewhere.

## Connect a new bank

```bash
banksync banks connect
```

Here is what happens:

1. The CLI snapshots the banks you already have.
2. It opens your browser to the app's connect flow, at a URL like `https://app.banksync.io/{workspaceId}/banks?connect=1`.
3. You complete the provider flow in the browser with your real session.
4. The CLI polls your workspace until the new bank appears, then prints it.

```text
Opened your browser to connect a bank. Waiting for the new connection...
⠹ waiting for a new bank
✓ connected

ID         NAME        SOURCE   TYPE      STATUS
bnk_x9y8   Wells Fargo plaid    personal  ● active
```

Polling runs for up to three minutes. If it times out, the connection may still have completed in the browser; run `banksync banks list` to check.

### Pre-select a provider or institution

Skip a step in the app by pre-seeding the flow:

```bash
banksync banks connect --provider plaid
banksync banks connect --institution ins_123
```

### Headless and non-interactive

Under `--no-input` (and automatically when there is no terminal), the CLI does not open a browser or poll. It prints the connect URL and exits, so you can open it on another device:

```bash
banksync banks connect --no-input
```

```text
Open this URL to connect a bank:
  https://app.banksync.io/ws_a1b2c3/banks?connect=1
```

> **Plan and role still apply:** The connect flow in the app is gated by your role, subscription, and bank limit. A read-only or
> capped user who follows the deep link may correctly land on a billing or limit dialog instead of
> the connect screen. That is expected: the CLI hands off to the same guarded flow the app uses.

## Reauthenticate a bank

When a connection needs re-consent (an expired or revoked provider session), send the user back into the app to fix it:

```bash
banksync banks reauth bnk_123
```

On a terminal this opens the browser to the reauth flow. When there is no browser, or under `--no-input`, it prints the URL to open manually. Reauth uses the same handoff pattern as connect.

## Search the institution catalog

Find connectable institutions before you connect, for example to grab an institution id to pre-seed:

```bash
banksync banks search chase
```

Narrow by country or provider:

```bash
banksync banks search "commonwealth" --country AU
banksync banks search chase --provider plaid:us -o json
```

- `--country` takes an ISO country code (for example `US`, `AU`).
- `--provider` takes a `providerInstanceId` (for example `plaid:us`).

```text
ID          NAME                      COUNTRY   PROVIDER
ins_3       Chase                     US        plaid:us
ins_57      Chase (Business)          US        plaid:us

2 institutions
```

## Inspect what you connected

After connecting, list banks and drill into accounts:

```bash
banksync banks list
banksync banks get bnk_x9y8
banksync accounts list bnk_x9y8
```

## Next steps

- [Syncing and jobs](/docs/cli/syncing-and-jobs): pull data from a connected bank.
- [Output formats](/docs/cli/output-formats): tables, JSON, and column control.
- [Authentication](/docs/cli/cli-authentication): API keys and profiles.
