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

# Sign and verify with React Native

> Sign messages and EIP-712 typed data and verify signatures against the active wallet.

Signing produces a signature without submitting a transaction. The React Native SDK signs and verifies against the active wallet, so these operations require a completed wallet session. The public verification methods do not accept an explicit wallet address.

## Sign and verify a message

Use the same network and exact message for signing and verification:

```typescript theme={null}
import { Networks } from '@0xsequence/oms-react-native-sdk'

const message = 'I authorize this action'

const signature = await omsWallet.wallet.signMessage({
  network: Networks.amoy,
  message,
})

const isValid = await omsWallet.wallet.isValidMessageSignature({
  network: Networks.amoy,
  message,
  signature,
})
```

`isValidMessageSignature` returns `false` when the signature does not validate for the active wallet, network, and message.

## Sign and verify typed data

Pass the EIP-712 data as a JSON-serializable object:

```typescript theme={null}
const typedData = {
  domain: {
    name: 'Example',
    version: '1',
    chainId: 80002,
  },
  types: {
    Action: [{ name: 'description', type: 'string' }],
  },
  primaryType: 'Action',
  message: {
    description: 'Approve action',
  },
}

const signature = await omsWallet.wallet.signTypedData({
  network: Networks.amoy,
  typedData,
})

const isValid = await omsWallet.wallet.isValidTypedDataSignature({
  network: Networks.amoy,
  typedData,
  signature,
})
```

The `chainId` in the EIP-712 domain remains part of the signed payload. The wallet method also requires the corresponding exported `network` value.

<Warning>
  Verification uses the currently active wallet. If the app switches wallets between signing and verification, switch back to the signer before calling the verification method.
</Warning>
