How to find NFT Collection By a Contract Address

Jerry An
2 min readJan 4, 2023

Using a contract address to find the NFT collection posted on Opensea is relatively simple. All you need to do is follow these steps:

1. Go to opensea.io

2. Enter a contract address into the search box, and the collection will be displayed on the page in a short period.

3. Click the collection link to view its detail page.

Automation

If you have a large number of contract addresses and need to get the associated collections, it is best to use a tool or script to automate the process.

Here is a Golang script.

package main

import (
"context"
"fmt"
"os/user"
"time"

"github.com/chromedp/chromedp"
)

var (
CHROME_EXEC_PATH = "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome"
USER_DATA_DIR = fmt.Sprintf("/Users/%s/Library/Application Support/Google/Chrome/", GetCurrentUserName())
PROFILE_DIRECTORY = "Default"
)

func GetCurrentUserName() string {
currentUser, _ := user.Current()
username := currentUser.Username
return username
}

type Collection struct {
Slug string
Address string
Chain string
}

func…

--

--