- Set up Reown AppKit.
- Configure a wallet connection modal and enable interactions with Tenderly’s Virtual TestNets.
Setup
In this section, you’ll learn how to set up the development environment to use AppKit with Tenderly’s Virtual TestNets. For this tutorial, we’ll be using Next.js, though you can use any other framework compatible with AppKit.AppKit is available on eight frameworks, including React, Next.js, Vue, JavaScript, React Native, Flutter, Android, iOS, and Unity.Now, let’s create a Next app. In order to do so, please run the command given below:
Install AppKit
Now, we need to install AppKit and other dependencies that we need for our app to function as expected. For this tutorial, we will be using “wagmi” as our preferred Ethereum library. However, you can also use Ethers.You can also use other package managers such asyarn
,bun
,pnpm
, etc.
Create a new project on Reown Dashboard
Now, we need to get a project Id from Reown Dashboard that we will use to set up AppKit with Wagmi config. Navigate to dashboard.reown.com and sign in. If you have not created an account yet, please do so before we proceed. After you have logged in, please navigate to the “Projects” section of the Cloud and click on “Create Project”.




Create a Virtual TestNet using Tenderly
Navigate to Tenderly Dashboard and login. If you don’t have an account already, then please sign up. Now, navigate to “Virtual TestNets” on the dashboard.

HTTPS
URL under “Public” as this will be your Virtual TestNet’s RPC URL.

Build the App
Before we build the app, let’s first configure our.env
file. On the root level of your code directory, create a new file named .env
.
Open that file and create a new variable NEXT_PUBLIC_PROJECT_ID
. You will assign the project Id that you copied in the previous step to this environment variable that you just created. You need to do the same for TENDERLY_VIRTUAL_TESTNET_RPC
. This is what it will look like:
Note: Please make sure you follow the best practices when you are working with secret keys and other sensitive information. Environment variables that start with
NEXT_PUBLIC
will be exposed by your app which can be misused by bad actors.Configure AppKit
We’ve created an in-depth technical guide on getting started with Reown AppKit on any EVM chain. Refer to the guide below to learn how to configure AppKit. A GitHub repository is also provided at the end of the guide, which you can clone to quickly get started. How to Get Started with Reown AppKit on Any EVM ChainConfigure Tenderly Virtual TestNet with AppKit
In order to set up Tenderly’s Virtual TestNet with AppKit, you need to first configure your Tenderly Virtual TestNet as a custom chain. Inside your/app
directory, create a new file named tenderly.config.ts
. Now, paste the code snippet shared below inside the code file, i.e., app/tenderly.config.ts
.
id
- set this to the chain Id that you passed while creating the Virtual TestNet on Tenderly.url
- set this with your your Virtual TestNet’s explorer URL. You can find this URL within your Virtual TestNet’s configuration on Tenderly Dashboard.

config/index.tsx
file, import vTestnet
from app/tenderly.config.ts
. You’ll also need to configure transports within the WagmiAdapter
function. Refer to the code snippet below.
context/index.tsx
file, you also need to import vTestnet
and pass it as one of the supported networks within the createAppKit
function, as shown below.
If you are using alternative package managers, you can try either of these commands -yarn dev
, orpnpm dev
, orbun dev
.
Conclusion
And that’s it! You have now learned how to create a simple app using AppKit and configure it with Tenderly Virtual TestNets.Tenderly Virtual TestNets Example
View the complete code repository here.