---
eip: 926
label: ERC-926
title: Address metadata registry
status: Stagnant
type: Standards Track
category: ERC
created: 2018-03-12
requires: 165
official: https://eips.ethereum.org/EIPS/eip-926
source: https://github.com/ethereum/ERCs/blob/master/ERCS/erc-926.md
canonical: https://eips.huatuo.xyz/eip-926/
lang: en
tldr: "Proposed one shared registry where any address points to a 'provider' contract that serves metadata about it, instead of every standard deploying its own registry; it is Stagnant."
tags: [registry, metadata, stagnant]
---

# ERC-926: Address metadata registry

> This EIP specifies a registry for address metadata, permitting both contracts and external accounts to supply metadata about themselves to onchain and offchain callers. This permits use-cases such as generalised authorisations, providing token acceptance settings, and claims registries.

**TL;DR:** Proposed one shared registry where any address points to a 'provider' contract that serves metadata about it, instead of every standard deploying its own registry; it is Stagnant.

## What problem does it solve?

More and more standards needed to attach information to an address: which tokens it accepts ([ERC-777](/eip-777/)), claims about it, or its human-readable name ([ERC-181](/eip-181/)). Each one shipped its own specialised registry contract, and the number kept growing.

ERC-926 proposes a single, generic "address metadata registry". Every address, contract or EOA, can register one **provider** contract, and that provider answers any metadata question about the address.

## How it works

**The registry** is tiny:

```solidity
interface AddressMetadataRegistry {
    function provider(address target) external view returns (address);
    function setProvider(address _provider) external;
}
```

`setProvider` records a provider for `msg.sender`; `provider(target)` returns it. The plan was to compile it with an agreed Solidity version and deploy it with a trustless deployment mechanism so it has the same address on every chain.

**Providers** do the real work:

- They must implement [ERC-165](/eip-165/) `supportsInterface`, returning true for `0x01ffc9a7` and for every metadata interface they support.
- The first argument of every provider function is the address being queried, so one provider contract can serve many users.
- If a metadata type needs several functions, a provider implements all of them or none, and throws on unknown function IDs.
- New metadata types are defined by future EIPs; the spec's table of standard interfaces is empty.

The design uses indirection instead of a generic key/value store. It costs an extra call, but lets each metadata type define its own functions and logic.

## Sample code

Looking up metadata through the registry (Solidity sketch, with a hypothetical metadata interface):

```solidity
interface IERC165 { function supportsInterface(bytes4 id) external view returns (bool); }
interface IRegistry { function provider(address target) external view returns (address); }

// Hypothetical metadata type defined by some future EIP
interface IAcceptsToken {
    function acceptsToken(address target, address token) external view returns (bool);
}

function accepts(IRegistry reg, address target, address token) view returns (bool) {
    address p = reg.provider(target);
    if (p == address(0)) return false;
    if (!IERC165(p).supportsInterface(IAcceptsToken.acceptsToken.selector)) return false;
    return IAcceptsToken(p).acceptsToken(target, token);
}
```

## Things to know

- **This proposal is Stagnant and was never adopted.** No canonical registry address was published, and no metadata interfaces were standardized under it.
- The interface-detection problem it targets was largely solved in practice by [ERC-820](/eip-820/) and its successor [ERC-1820](/eip-1820/), which map an address plus interface name to an implementer contract.
- Because each address has exactly one provider, adding a new kind of metadata means switching to (or upgrading) a provider that supports both old and new types.
- The reference implementation in the spec is only a `mapping(address => address)` with a setter. All the logic lives in providers.


---

This is an unofficial plain-language summary. Read the full specification: https://eips.ethereum.org/EIPS/eip-926
