# invalid_hostname

That is not a valid hostname.

## What it means

The value is not a hostname we can serve. We accept a fully qualified name like `careers.acme.com`, including internationalised names.

## Why it happens

- It carries a scheme, path or port: `https://careers.acme.com/`.
- It is a wildcard (`*.acme.com`) or an IP address.
- It has an empty label, a label over 63 characters, or characters not allowed in DNS.
- For `whitelabel_host`: the host is already used by another app.

## What to do

1. Send just the name: lowercase, no scheme, no trailing dot or slash.
2. Strip what your customer typed with a URL parser before sending it.
3. `error.message` says which rule failed.

- [Open the dashboard](/app/domains)
- [All limits](/docs/limits-and-pricing)

## In the API

```
HTTP 422

{
  "error": {
    "code": "invalid_hostname",
    "message": "That is not a valid hostname.",
    "fix": "Send a hostname like careers.acme.com: no scheme, path, port, wildcard or IP address.",
    "docs": "https://apexly.dev/docs/errors/invalid_hostname"
  }
}
```
