# Terra Connect: connect Terra Wallet users to your dApp

> Add Terra Wallet to your dApp: WalletConnect integration, EIP-1193, EIP-6963 and the Solana Wallet Standard work today. A connect wallet button is next.

Source: https://developers.terrawallet.us/connect

**Status:** Connecting to Terra Wallet works today through open standards. The Terra Connect SDK and widgets are in early access.

## Let Terra Wallet users into your dApp

Terra Wallet already works with your WalletConnect integration and injected providers, so dApp wallet connection needs no extra code. Soon, a drop-in connect wallet button and wallet modal make it a five-minute job.

## Works with your WalletConnect integration today

No SDK needed: Terra Wallet answers like any other standard wallet.

- **EIP-1193** (Live): The standard provider, injected as `window.ethereum` in the Terra Wallet extension and in the app's dApp browser.
- **EIP-6963** (Live): Multi-wallet discovery: Terra Wallet announces itself with rdns `com.terrawallet.app` next to other wallets.
- **Solana Wallet Standard** (Live): Solana dApps list Terra Wallet by name. A legacy `window.solana` provider is also there.
- **WalletConnect v2** (Live): From any desktop or mobile dApp: users scan your WalletConnect QR code with Terra Wallet.

- Every signature and transaction needs the user's explicit approval in the wallet.
- The extension checks the requesting site against a phishing list and shows a readable summary of each request.
- `eth_sign` is disabled for safety: use `personal_sign` or `eth_signTypedData_v4`.
- dApp connections work on Ethereum, BNB Smart Chain, Polygon, Avalanche, Arbitrum, Optimism, Base, Fantom and Solana.

EIP-6963 (works today):

```js
// Works today: find Terra Wallet through EIP-6963.
const wallets = new Map();
window.addEventListener("eip6963:announceProvider", (event) => {
  wallets.set(event.detail.info.uuid, event.detail);
});
window.dispatchEvent(new Event("eip6963:requestProvider"));

// Call from a user action, such as a click.
async function connectTerraWallet() {
  const terra = [...wallets.values()].find(
    (w) => w.info.rdns === "com.terrawallet.app",
  );
  if (!terra) throw new Error("Terra Wallet is not available");
  const [account] = await terra.provider.request({
    method: "eth_requestAccounts",
  });
  return account;
}
```

WalletConnect (works today):

```js
// Works today: users scan your WalletConnect QR in Terra Wallet.
// npm i @walletconnect/ethereum-provider
import { EthereumProvider } from "@walletconnect/ethereum-provider";

const provider = await EthereumProvider.init({
  projectId: "<your-reown-project-id>",
  chains: [1],                     // Ethereum
  optionalChains: [56, 137, 8453], // BNB Chain, Polygon, Base
  showQrModal: true,
});

const accounts = await provider.enable();
```

## A connect wallet button that finds the wallet for you

The `connect` package finds Terra Wallet through EIP-6963 and the Wallet Standard, and falls back to WalletConnect v2 with a QR code or an app deep link.

- **Small and fast** (Early access): A target under 15 KB gzipped. WalletConnect loads lazily, only when it's needed.
- **Everything after connect** (Early access): Sessions, chain switching, signing and sending, with typed errors.
- **Mobile-first** (Early access): On a phone, Connect opens the Terra app directly and returns to your dApp by itself.
- **Your look, our safety** (Early access): Theme the accent, radius, font and light or dark mode. Terra's security prompts can't be hidden or restyled.
- **Shadow DOM** (Early access): The widget renders in Shadow DOM, so page CSS can't break or spoof it.
- **Accessible** (Early access): WCAG AA, keyboard and screen-reader support, and right-to-left languages.

React (Preview API, subject to change):

```tsx
// Preview API, subject to change. Package names may change.
import { TerraProvider, ConnectButton, useAccount } from "@terrawallet/react";

export function App() {
  return (
    <TerraProvider
      publishableKey="tw_test_pk_..."   // safe in the browser
      theme={{ accent: "#0A5BFF", mode: "auto" }}
    >
      <ConnectButton />
      <Balance />
    </TerraProvider>
  );
}

function Balance() {
  const { address, chain } = useAccount();
  return address ? <p>{chain.name}: {address}</p> : null;
}
```

_Package names are illustrative and may change before launch._

## Frequently asked questions

### Does Terra Wallet work with my dApp today?

Yes, if your dApp supports WalletConnect v2, EIP-1193 or EIP-6963 on EVM networks, or the Solana Wallet Standard. Terra Wallet answers like any standard wallet.

### Which networks support dApp connections?

Ethereum, BNB Smart Chain, Polygon, Avalanche, Arbitrum, Optimism, Base, Fantom and Solana.

### How do users connect from a desktop browser?

With the Terra Wallet extension, which injects an EIP-1193 provider and announces itself through EIP-6963, or by scanning your WalletConnect QR code with the Terra Wallet app.

### What is Terra Wallet's EIP-6963 rdns?

Terra Wallet announces itself with rdns `com.terrawallet.app`.

### Is the Connect SDK available?

Not yet. The Connect SDK and widgets are in early access. You can support Terra Wallet users today with the standard code on this page, and preview the SDK on the [SDK and widgets](/sdk) page.

### Can a connected dApp move funds without asking?

No. A connection is never permission to sign. Every signature and transaction needs the user's explicit approval, with a readable summary of the request.
