# indexer.getRegistryLabels

> For the complete documentation index, see [llms.txt](https://ensforge.com/llms.txt).

Lists the labels of an ENSv2 registry, optionally only those an address holds or does not hold. Options, errors and examples for indexer.getRegistryLabels.

Source: https://ensforge.com/docs/reference/sdk/indexer/get-registry-labels

<ApiMeta kind="Read" stability="stable" since="1.0.0" source="packages/sdk/src/actions/indexer/getRegistryLabels/index.ts#L51" batchable />

Lists the labels of an ENSv2 registry, optionally only those an address holds or does not hold.

## When to use [#when-to-use]

Use to browse a registry's names, e.g. the subnames recreated during migration.

## Details [#details]

- `owner` and `excludeOwner` cannot be combined.

## Signature [#signature]

```ts
function getRegistryLabels(
  client: Like,
  options: getRegistryLabels.Options,
): Promise<getRegistryLabels.ReturnType>
```

Call it as `ens.indexer.getRegistryLabels(options)` on a client, or `Actions.indexer.getRegistryLabels(client, options)`.

`indexer.getRegistryLabels.request(options)` builds a deferred read for `Actions.batch`. See [Look up many at once](/docs/sdk/look-up-many-at-once).

## Parameters [#parameters]

| Option | Type | Default | Description |
| --- | --- | --- | --- |
| `limit` | `number` |  | Rows per page, 1–200. @default 50 |
| `cursor` | `string` |  | The previous page's `cursor`. |
| `includeTotal` | `boolean` |  | Count every row (`totalCount`); slower. |
| `address` (required) | `string` |  | Contract address. |
| `chainId` | `number` |  | Chain of the contract. @default the client's chain |
| `owner` | `string` |  | Only labels this address holds. |
| `excludeOwner` | `string` |  | Only labels this address does not hold. |

Also takes the [read options](/docs/reference/sdk/client#read-options).

## Returns [#returns]

Resolves to `Page<RegistryLabel>`. One page of labels.

## Errors [#errors]

| Error | Codes | When |
| --- | --- | --- |
| [`InvalidInputError`](/docs/reference/errors/invalid-input-error) | [`INVALID_ADDRESS`](/docs/reference/errors/INVALID_ADDRESS) | an invalid address. |
| [`ConfigError`](/docs/reference/errors/config-error) | [`INDEXER_NOT_CONFIGURED`](/docs/reference/errors/INDEXER_NOT_CONFIGURED) | the client has no indexer. |
| [`IndexerError`](/docs/reference/errors/indexer-error) | [`INDEXER_UNSUPPORTED`](/docs/reference/errors/INDEXER_UNSUPPORTED) | the indexer does not serve the query or its namespace. |
| [`IndexerError`](/docs/reference/errors/indexer-error) | [`INDEXER_UNAVAILABLE`](/docs/reference/errors/INDEXER_UNAVAILABLE), [`INDEXER_RATE_LIMITED`](/docs/reference/errors/INDEXER_RATE_LIMITED), [`INDEXER_BEHIND`](/docs/reference/errors/INDEXER_BEHIND), [`INDEXER_REQUEST_REJECTED`](/docs/reference/errors/INDEXER_REQUEST_REJECTED), [`INDEXER_RESPONSE_INVALID`](/docs/reference/errors/INDEXER_RESPONSE_INVALID) | the indexer is unavailable, rate limiting, behind, rejects the request or answers unexpectedly. |

It can also fail with the errors every read can (`Errors.CommonError`: `ConfigError`, `ContractRevertError`, `InternalError`, `NetworkError`).

See [How errors work](/docs/sdk/errors-explained).

## Examples [#examples]

<Tabs groupId="api" items={["Client","Standalone","Effect"]} persist>
<Tab>
```ts title="Listing a registry's labels"
const page = await ens.indexer.getRegistryLabels({ address: "0x02ca…" })
```
</Tab>

<Tab>
```ts title="Listing labels an address holds with a standalone call"
import { Actions } from "@ensforge/sdk"

const page = await Actions.indexer.getRegistryLabels(ens, { address, owner: account })
```
</Tab>

<Tab>
```ts title="Listing a registry's labels in an Effect program"
import { Actions } from "@ensforge/sdk/effect"

const page = yield* Actions.indexer.getRegistryLabels(ens, { address, limit: 200 })
```
</Tab>
</Tabs>

## Example response [#example-response]

Recorded from Ethereum mainnet on 2026-11-18 at block 26443964. Values change as the chain does.

```ts
await ens.indexer.getRegistryLabels({ address: "0x00000000000C2E074eC69A0dFb2997BA6C7d2e1e", chainId: 1, limit: 3 })
```

```json
{
  "asOf": {
    "chainId": 1,
    "blockNumber": "26443964n",
    "blockHash": "0xe75c58ea2f28bd7c6cc53c28a5ab4fc02023f3563661f0a7236a36b779e3ac86",
    "timestamp": "1795029143n"
  },
  "snapshots": {
    "1": {
      "chainId": 1,
      "blockNumber": "26443964n",
      "blockHash": "0xe75c58ea2f28bd7c6cc53c28a5ab4fc02023f3563661f0a7236a36b779e3ac86",
      "timestamp": "1795029143n"
    }
  },
  "asOfToken": null,
  "completeness": "full",
  "unsupportedReason": null,
  "unsupportedFields": [],
  "origin": null,
  "indexer": "bigname",
  "items": [],
  "cursor": null,
  "hasMore": false,
  "totalCount": 0
}
```