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

# Fetch Balance

> [card] Recommended: JavaScript SDK for React Native
>
> While this SDK is still supported, we recommend using newer [JavaScript SDK](https://docs.dynamic.xyz/docs/javascript/reference/react-native-quickstart.md), which is optimized for React Native, but also comes with a host of other benefits.

You can show a wallet's full portfolio by using the `getMultichainBalances` method on the wallets module, which batches token balances across chains and networks in a single call.

```typescript React Native theme={"system"}
import { dynamicClient } from '<path to client file>';
import { ChainEnum } from '@dynamic-labs/sdk-api-core';

const wallet = dynamicClient.wallets.primary;

if (wallet) {
  const chainBalances = await dynamicClient.wallets.getMultichainBalances({
    balanceRequest: {
      filterSpamTokens: true,
      balanceRequests: [
        {
          address: wallet.address,
          chain: ChainEnum.Evm,
          networkIds: [1, 137, 56], // Ethereum, Polygon, BNB
        },
      ],
    },
  });
}
```

Each token entry includes `marketValue` (USD value) and `price` (USD per unit), so the total portfolio value is the sum of `marketValue` across tokens:

```typescript React Native theme={"system"}
const totalUsd = chainBalances
  ?.flatMap((chain) => chain.networks)
  .flatMap((network) => network.balances ?? [])
  .reduce((sum, token) => sum + (token.marketValue ?? 0), 0);
```

## Native asset balance

> [!NOTE]
>
> `getBalance` returns the native asset only (for example ETH on Ethereum, SOL on Solana) for the wallet's active network. For total portfolio value across tokens and chains, use `getMultichainBalances` above.

To show the balance of just the wallet's native asset, use `dynamicClient.wallets.getBalance()`. You can get the balance for the primary wallet or any specific wallet instance.

```ts React Native theme={"system"}
import { dynamicClient } from '<path to client file>';

// Get balance for the primary wallet
const primary = dynamicClient.wallets.primary;
if (primary) {
  const { balance } = await dynamicClient.wallets.getBalance({ wallet: primary });
  // e.g. set state with balance
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.