Skip to main content

Share one set of subnames across several names [ENS Explorer]

Point ENSv2 names at one name's registry in ENS Explorer, so the same subnames work under each of them.

Several ENSv2 names can share one set of subnames. A name keeps its subnames in a registry. Point other names at the same registry and every subname in it works under each of them: pay.anchovy.eth and pay.salmon.eth are then one subname, with one owner.

anchovy.eth and salmon.eth both point to one subname registry, so pay, team and wallet work under both names

How subnames and records work

A name's subnames and records are held in two places, each with its own roles:

  • Registry: holds the name's subnames. Its registry roles decide who can add subnames (Registrar) and delete them (Unregister).

  • Resolver: holds the records, such as addresses and profile. Its resolver roles decide who can edit them, such as Set Address and Set Text.

Point several names at one registry and they share its subnames, and its registry roles decide who can add or delete them. Records stay on the resolver, kept for each name: see Do shared subnames share records?

Before you start

  • All the names are on ENSv2.

  • The first name already has its own registry. If not, set one up first: see Create a subname (ENS Explorer).

  • Your wallet holds the Set Subregistry role on each other name. When you register a .eth name, your wallet gets it. See Which roles do I need?

Share subnames in ENS Explorer

  1. Open the first name in ENS Explorer and go to Registry. Copy the registry's address.

  2. Open another name and go to Registry. Select + Configure registry, or Reconfigure if it already has one.

  3. Choose Use a pre-existing registry contract and paste the address. Select Deploy and approve in your wallet.

When it confirms, that name's Subnames shows the same list as the first name's. Repeat steps 2 and 3 for each name that should share.


Common questions

Which roles do I need?

You need different roles for different jobs. ENS Explorer shows them all on a name's Roles tab:

  • To point a name at the registry: the Set Subregistry registry role on that name. Find your wallet in Parent registry / Roles.

  • To add or delete shared subnames: the Registrar and Unregister registry roles on the shared registry. Find them in <name> Registry / Roles on the first name.

  • To edit records: resolver roles such as Set Address and Set Text, on the name's resolver.

Setting up a registry gives your wallet every registry role on it. To give roles to another wallet, see Grant registry 'roles' to manage your name and Grant resolver 'roles' to edit name records.

Who can add or delete shared subnames?

Any wallet with the Registrar role on the shared registry can add subnames, and one with Unregister can delete them. The roles sit on the registry, not on a name, so a change shows under every name that uses it. Add pay once, and pay.anchovy.eth and pay.salmon.eth both work.

Do shared subnames share records?

No, shared subnames don't share records. Records live on the resolver, kept for each name, so an address set on pay.anchovy.eth doesn't show on pay.salmon.eth. To make them match, set the same records on each, or link one name to the other's records. Linking needs the Link role on their resolver ("Can link names to shared records").

What happens to subnames a name already had?

Subnames a name already had stop working under it once it uses the other registry, because the name reads the other registry's list.

What if one of the names expires?

If a name expires, the shared subnames stop working under that name.

Did this answer your question?