# registration.getRenewalPrice

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

Quotes renewing one or more .eth names, in an ERC-20 payment token. Options, result, errors and examples for registration.getRenewalPrice.

Source: https://ensforge.com/docs/reference/sdk/registration/get-renewal-price

<ApiMeta kind="Read" stability="stable" since="1.0.0" source="packages/sdk/src/actions/registration/getRenewalPrice/index.ts#L53" batchable />

Quotes renewing one or more `.eth` names, in an ERC-20 payment token.

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

Use to show the cost of extending names before calling [`registration.renew`](/docs/reference/sdk/registration/renew).

## Details [#details]

- ENSv2 names renew through the `ETHRegistrar`; names still on ENSv1 renew through
  `ETHRenewerV1`. Each item says which (`route`).
- Costs one batched call for any number of names.

## Signature [#signature]

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

Call it as `ens.registration.getRenewalPrice(options)` on a client, or `Actions.registration.getRenewalPrice(client, options)`.

`registration.getRenewalPrice.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 |
| --- | --- | --- | --- |
| `names` (required) | `string \| readonly string[]` |  | One or more `.eth` second-level names. Normalized automatically. |
| `duration` (required) | `bigint` |  | Renewal length in seconds. |
| `paymentToken` | `PaymentToken` | `"usdc"` | Token to pay with. |

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

## Returns [#returns]

Resolves to `getRenewalPrice.ReturnType`. The total and one item per name, in `token` units.

| Field | Type | Description |
| --- | --- | --- |
| `total` | `bigint` |  |
| `token` | `TokenInfo` |  |
| `items` | `readonly { readonly name: string; readonly route: RenewalRoute; readonly amount: bigint; }[]` |  |

## Errors [#errors]

| Error | Codes | When |
| --- | --- | --- |
| [`InvalidInputError`](/docs/reference/errors/invalid-input-error) | [`INVALID_NAME`](/docs/reference/errors/INVALID_NAME), [`INVALID_ADDRESS`](/docs/reference/errors/INVALID_ADDRESS) | invalid input. |
| [`NameStateError`](/docs/reference/errors/name-state-error) | [`NAME_NOT_RENEWABLE`](/docs/reference/errors/NAME_NOT_RENEWABLE) | a name is neither registered nor in its grace period. |
| [`UnsupportedError`](/docs/reference/errors/unsupported-error) | [`PAYMENT_TOKEN_UNSUPPORTED`](/docs/reference/errors/PAYMENT_TOKEN_UNSUPPORTED), [`UNSUPPORTED_ON_DEPLOYMENT`](/docs/reference/errors/UNSUPPORTED_ON_DEPLOYMENT) | an unaccepted token or without ENSv2. |
| [`NetworkError`](/docs/reference/errors/network-error) | [`RPC_REQUEST_FAILED`](/docs/reference/errors/RPC_REQUEST_FAILED), [`RPC_TIMEOUT`](/docs/reference/errors/RPC_TIMEOUT), [`RATE_LIMITED`](/docs/reference/errors/RATE_LIMITED) | the RPC request fails. |

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="Quoting two names"
const { total, items } = await ens.registration.getRenewalPrice({ names: ["alice.eth", "bob.eth"], duration: 31536000n })
```
</Tab>

<Tab>
```ts title="Quoting with a standalone call"
import { Actions } from "@ensforge/sdk"

const quote = await Actions.registration.getRenewalPrice(publicClient, { names: "nick.eth", duration: 31536000n })
```
</Tab>

<Tab>
```ts title="Quoting in an Effect program"
import { Actions } from "@ensforge/sdk/effect"

const quote = yield* Actions.registration.getRenewalPrice(ens, { names: "nick.eth", duration: 31536000n })
```
</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.registration.getRenewalPrice({ names: "nick.eth", duration: 31_536_000n })
```

```json
{
  "total": "160000009n",
  "token": {
    "address": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
    "symbol": "USDC",
    "decimals": 6
  },
  "items": [
    {
      "name": "nick.eth",
      "route": "v2-registrar",
      "amount": "160000009n"
    }
  ]
}
```

## See also [#see-also]

- [`registration.renew`](/docs/reference/sdk/registration/renew) to renew