# predictModularAccountV2Address | @account-kit/smart-contracts

> Overview of the predictModularAccountV2Address function from @account-kit/smart-contracts

> For the complete documentation index, see [llms.txt](/docs/llms.txt).

{/* This file is auto-generated by TypeDoc. Do not edit manually. */}

```ts
function predictModularAccountV2Address(params): `0x${string}`;
```

Defined in: [account-kit/smart-contracts/src/ma-v2/account/predictAddress.ts:51](https://github.com/alchemyplatform/aa-sdk/blob/main/account-kit/smart-contracts/src/ma-v2/account/predictAddress.ts#L51)

Predicts the address of a modular account V2 based on the provided parameters, which include factory address, salt, and implementation address. This function supports different types of accounts including "SMA", "MA", and "WebAuthn".

## Example

```ts
import { predictModularAccountV2Address } from "@account-kit/smart-contracts";

const accountAddress = predictModularAccountV2Address({
  factoryAddress: "0xFactoryAddress" as Address,
  implementationAddress: "0xImplementation" as Address,
  salt: 0n,
  type: "SMA",
  ownerAddress: "0xOwner" as Address,
});
```

## Parameters

<table>
  <thead>
    <tr>
      <th align="left">Parameter</th>
      <th align="left">Type</th>
      <th align="left">Description</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `params`
      </td>

      <td>
        `PredictModularAccountV2AddressParams`
      </td>

      <td>
        The parameters for predicting the modular account address, including `factoryAddress`, `salt`, `implementationAddress`, and additional properties based on the account type.
      </td>
    </tr>

  </tbody>
</table>

## Returns

`` `0x${string}` ``

The predicted address for the modular account V2.