> ## 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.

# Get Wallet 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.

```ts React Native theme={"system"}
    // Using the RN client directly
    import { dynamicClient } from '<path-to-your-dynamicClient>';

    export const getPrimaryBalance = async () => {
      const wallet = dynamicClient.wallets.primary;
      if (!wallet) return null;
      const balance = await wallet.getBalance();
      return balance?.toString() ?? null;
    }
```


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