# Register a domain

> Search for a free domain name, see its price and register it with Coritan from the Websites page.

Source: https://www.coritan.com/docs/websites/domains/register-a-domain/

In the dashboard:

- /dashboard/websites: https://www.coritan.com/dashboard/websites

Register a domain when you want Coritan to hold its registration as well as its DNS. The domain is yours for the period you pay for, starts on Coritan's nameservers, and can have its DNS zone, a certificate and a web proxy set up at the same time.

## Before you begin

- Make sure your account credit covers the price for the whole period. Coritan takes it before it registers the domain ([Add credit](/docs/billing/add-credit/)).
- Check the prices: select **View domain prices** in the Websites list's **More website actions** menu.

## Register the domain

1. In the dashboard, go to [Websites](https://www.coritan.com/dashboard/websites) and select **Register domain…**.
2. Enter the **Domain name**, such as `example.com`, and select **Search**.
3. Read the result. The dialog says whether the domain is available, shows its **Price per year**, and marks a premium domain, whose price its registry sets. If it is taken, select **Back** and search for another name.
4. Choose the **Registration period**, from 1 to 10 years.
5. Choose the options:
   - **Issue an SSL certificate** (on at first) requests a certificate for the web proxy that the next option sets up.
   - **Set up a proxy route** (off at first) creates a web proxy for the domain.
   - **WHOIS privacy** (off at first) hides your contact details from public WHOIS lookups.
6. Select **Register domain**.

## Result

The dashboard confirms that the domain is registered, and it appears in the Websites list. The registration starts with:

- the transfer lock and auto-renew on, and WHOIS privacy on if you chose it;
- Coritan's nameservers, `ns1.coritan.com` to `ns8.coritan.com`;
- a DNS zone hosted on Coritan, signed with DNSSEC, when **Issue an SSL certificate** or **Set up a proxy route** was on.

> [!IMPORTANT]
> With both options off, Coritan creates no DNS zone, so the domain does not resolve. Select **Add existing domain…** and enter the domain to create its zone ([Add a domain you already own](/docs/websites/add-an-existing-domain/)).

The web proxy that **Set up a proxy route** creates has no origin of yours yet, so visitors see an error until you [set its origin](/docs/proxies/web-proxies/change-the-origin/). Coritan requests the certificate only for that proxy. With **Set up a proxy route** off, [issue the certificate](/docs/websites/ssl/issue-a-certificate/) from the domain's **SSL** tab once you need one.

Next, [add the domain's DNS records](/docs/websites/dns/manage-dns-records/).

## Troubleshooting

`Insufficient credit balance. Required: 22.49 USD, available: 10.00`
: The account credit does not cover the price for the period. [Add credit](/docs/billing/add-credit/), or choose a shorter period.

`Domain is not available for registration`
: Someone else holds the domain. Search for another name.

`Domain already registered in our system`
: The domain is already registered through Coritan, on your account or another.

`Registration failed: …` or `Registrar error: …`
: The registry refused the registration or did not answer. Coritan gives back the charge. Try again later.

`Invalid domain name format`
: Enter the bare domain, such as `example.com`, without `https://` or a path.

## Related

- [How domain registration works](/docs/websites/domains/)
- [Renew a domain](/docs/websites/domains/renew-a-domain/)
- [Turn on WHOIS privacy and transfer lock](/docs/websites/domains/whois-privacy-and-transfer-lock/)

## With the API

Check the name first. The price is per year, as a string:

```bash
curl -X POST https://api.coritan.com/api/v1/domains/search \
  -H "Authorization: Bearer $CORITAN_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"domain": "example.com"}'
```

```json
{"domain": "example.com", "available": true, "price": "14.99", "currency": "USD", "premium": false}
```

Then register it. The body takes `domain`, `duration` (1–10 years, 1 when you leave it out), `whois_privacy`, `auto_ssl`, `auto_proxy` and, optionally, `nameservers`, a list of the nameservers to start with instead of Coritan's.

> [!NOTE]
> The API's defaults differ from the dashboard's: `auto_ssl`, `auto_proxy` and `whois_privacy` are all `true` when you leave them out. Send each one you want off as `false`.

```bash
curl -X POST https://api.coritan.com/api/v1/domains/register \
  -H "Authorization: Bearer $CORITAN_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"domain": "example.com", "duration": 2, "whois_privacy": true, "auto_ssl": true, "auto_proxy": false}'
```

The answer is `201` with the registration, in the shape [How domain registration works](/docs/websites/domains/#read-registrations-with-the-api) shows. `dns_zone_id` names the DNS zone Coritan created, and `proxy_route_id` the web proxy.

## API

- `POST /api/v1/domains/search`: Check domain availability and pricing (includes markup) (https://www.coritan.com/docs/api/reference/client/domains/#op-post-api-v1-domains-search)
- `POST /api/v1/domains/register`: Register a new domain name (https://www.coritan.com/docs/api/reference/client/domains/#op-post-api-v1-domains-register)
