How to verify smart contract

Submit your smart contract code for independent verification and publishing on Avascan

If you'd like to verify contracts via our website, you may do so using the Verify Contract page.

With the Etherscan Compatible Verify Contract API, verify smart contract on Avascan is now more easy than ever. There are few things you need to connect your favorite verify contract client with Etherscan compatibility:

  1. Define the networkId: mainnet, testnet

  2. Retrieve the chainId of the evm compatible blockchain. You can use the all blockchains page.

  3. Compose the Etherscan Compatible API endpoint:

The following endpoints are provided only as an example:

BlockchainAPI Endpoint (https)










hardhat-etherscan, is an hardhat plugin, that simplify the smart contract verification process on Etherscan. With the Etherscan Compatible Verify Contract API, you can use this tool to verify your smart contract on Avascan as well.

Let's say you want to verify your smart contract on wagmi, this is an example of hardhat.config.ts:

import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";
import "@nomiclabs/hardhat-etherscan";

const config: HardhatUserConfig = {
  etherscan: {
    apiKey: {
      wagmi: "avascan", // apiKey is not required, just set a placeholder
    customChains: [
        network: "wagmi",
        chainId: 11111,
        urls: {
          apiURL: "",
          browserURL: ""

  networks: {
    wagmi: {
      url: '',
      accounts: [process.env.PRIVATE_KEY]

export default config;


npx hardhat run scripts/deploy.ts --network wagmi


export PRIVATE_KEY=...
npx hardhat verify --network wagmi 0x...

If you need any support just ask in our Discord server or our Telegram group.

Last updated