Reown AppKit Core is the upgraded version of WalletConnect Modal. It provides a user-friendly experience while maintaining the familiar QR code functionality for wallet connections. AppKit Core is the base version of Reown AppKit that includes the traditional WalletConnect Modal with QR code functionality.

This is a preview version of Reown AppKit Core.

Please, follow the different sections based on which package you were using before.

  1. @walletconnect/ethereum-provider
  2. @walletconnect/universal-provider
  3. @walletconnect/sign-client
  4. @walletconnect/modal

If your project has @walletconnect/modal in the package.json or your project files, you need to remove it and uninstall it. After that, you can refer to the Universal Provider path to setup AppKit Core in your project.

AppKit Core is the most basic version of Reown AppKit which replaces WalletConnect Modal. Please refer to this section if you are starting from scratch.

Installation

You first need to install the AppKit package in order to get started. You can do this by running the command below.

Make sure to use a version equal or greater than v1.7.0

npm install @reown/appkit

Ethereum Provider

The Ethereum Provider implementation remains the same as before. Projects and developers don’t need to change anything in their configuration; upgrading the Ethereum Provider to latest version is sufficient. Projects will automatically receive the new QR modal UI.

Not all themeVariableswill be compatible with the new UI, as AppKit uses a different design system than walletConnectModal

Examples

Below are the examples for the corresponding library/programming language.

  1. HTML
  2. React
  3. NextJS
  4. Vue

Universal Provider

First, please uninstall the @walletconnect/modal package. You should also remove @walletconnect/modal from your package.json file.

npm uninstall @walletconnect/modal

Then, you can use the following code to configure AppKit with UniversalProvider.

// Remove the code lines below the comment that says "Remove the code line below"
// Add the code lines in green

import { UniversalProvider } from '@walletconnect/universal-provider'

// Remove the code line below
import { WalletConnectModal } from '@walletconnect/modal'

// Add the code lines below
import { mainnet, solana } from '@reown/appkit/networks'
import { createAppKit } from '@reown/appkit/core'

const provider = await UniversalProvider.init({
  projectId: 'YOUR_PROJECT_ID',
  metadata: {
    name: 'My Website',
    description: 'My Website Description',
    url: 'https://mywebsite.com', // origin must match your domain & subdomain
    icons: ['https://avatars.githubusercontent.com/u/37784886']
  },
})

// Remove the code lines below
const modal = new WalletConnectModal({
  projectId: 'YOUR_PROJECT_ID',
  chains: ['eip155:1', 'solana:mainnet']
})

// listen to display_uri event and feed modal with uri
provider.on('display_uri', (uri: string) => {
  modal.openModal({ uri })
})

// Add the code lines below
const modal = createAppKit({
  projectId: 'YOUR_PROJECT_ID',
  networks: [mainnet, solana],
  universalProvider: provider,
  manualWCControl: true
})
// A spinner will be showing until it's connected.
modal.open()

// Connect provider, this will trigger display_uri event
await provider.connect({
  optionalNamespaces: {
    eip155: {
      methods: [
        'eth_sendTransaction',
        'eth_signTransaction',
        'eth_sign',
        'personal_sign',
        'eth_signTypedData'
      ],
      chains: ['eip155:1'],
      events: ['chainChanged', 'accountsChanged']
    },
    solana: {
      methods: ['solana_signMessage', 'solana_signTransaction'],
      chains: ['solana:mainnet'],
      events: ['chainChanged', 'accountsChanged']
    }
  }
})

How to use a Custom Network

WalletConnect Modal has always been chain agnostic. AppKit Core is chain agnostic as well. Hence, you can configure custom networks like Polkadot, Cosmos, etc., using AppKit Core.

Examples

Below are the examples for the corresponding library/programming language.

  1. HTML
  2. React
  3. NextJS
  4. Vue

Sign Client

First, please uninstall the @walletconnect/modal package. You should also remove @walletconnect/modal from your package.json file.

npm uninstall @walletconnect/modal

Then, you can use the following code to configure AppKit with SignClient.

import { SignClient } from '@walletconnect/sign-client'

// Remove the code line below
import { WalletConnectModal } from '@walletconnect/modal'

// Add the code lines below
import { mainnet } from '@reown/appkit/networks'
import { createAppKit } from '@reown/appkit/core'

const signClient = await SignClient.init({
  projectId: 'YOUR_PROJECT_ID',
  metadata: {
    name: 'My Website',
    description: 'My Website Description',
    url: 'https://mywebsite.com', // origin must match your domain & subdomain
    icons: ['https://avatars.githubusercontent.com/u/37784886']
  },
})

// Remove the code lines below
const modal = new WalletConnectModal({
  projectId: 'YOUR_PROJECT_ID',
  chains: ['eip155:1']
})

// Add the code lines below
const modal = createAppKit({
  projectId: 'YOUR_PROJECT_ID',
  networks: [mainnet],
  manualWCControl: true
})

// connect signClient and feed uri to modal
const { uri, approval } = await signClient.connect({
    requiredNamespaces: {
      eip155: {
        methods: [
          'eth_sendTransaction',
          'eth_signTransaction',
          'eth_sign',
          'personal_sign',
          'eth_signTypedData'
        ],
        chains: ['eip155:1'],
        events: ['chainChanged', 'accountsChanged']
      }
    }
  })

  if (uri) {
    modal.openModal({ uri })
    const session = await approval()
    modal.closeModal()
  }

How to use a Custom Network

WalletConnect Modal has always been chain agnostic. AppKit Core is chain agnostic as well. Hence, you can configure custom networks like Polkadot, Cosmos, etc., using AppKit Core.

Examples

Below are the examples for the corresponding library/programming language.

  1. HTML
  2. React
  3. NextJS
  4. Vue

Setting up AppKit Core from scratch

If you are setting up AppKit Core from scratch, you can refer to the “Multichain” section under AppKit “Core” for installation which shows a basic installation of AppKit Core. Click here to learn more.

Examples

Below are the examples for the corresponding library/programming language.

  1. HTML
  2. React
  3. NextJS
  4. Vue