> ## Documentation Index
> Fetch the complete documentation index at: https://docs.purpify.host/llms.txt
> Use this file to discover all available pages before exploring further.

# Connect a custom domain to a Java server

> Point play.example.com to a Purpify Minecraft Java Edition server with DNS address and SRV records.

Use an address record for the server IP and an SRV record when players must be sent to a non-default server port. After DNS is configured, Java players can connect with an address such as `play.example.com`.

This guide applies to Minecraft Java Edition. Native Bedrock clients do not all resolve Minecraft SRV records consistently, so Bedrock players may still need the Purpify server address and server port.

## Address and port are separate

| Value          | Example            | Purpose                                           |
| -------------- | ------------------ | ------------------------------------------------- |
| Server address | `203.0.113.20`     | Identifies the server on the network.             |
| Server port    | `25570`            | Identifies the Minecraft service on that address. |
| Custom domain  | `play.example.com` | Gives players a memorable name to enter.          |

An `A` record maps a hostname to an IPv4 address. It does not carry a port. An SRV record tells compatible clients which hostname and port provide a service.

<Warning>
  Use the address and port assigned in the Purpify game panel. Do not change `server-ip` or `server-port` in `server.properties` to match your domain.
</Warning>

## Configure a server on the default port

When the Purpify allocation uses the standard Java port, create an address record:

| DNS field        | Example value                             |
| ---------------- | ----------------------------------------- |
| Type             | `A`                                       |
| Name or host     | `play`                                    |
| Value or content | `203.0.113.20`                            |
| TTL              | Automatic or your provider's normal value |

Replace the example IP with the address assigned to your server. Players then connect with `play.example.com`.

## Configure a server with a custom port

First create a hostname for the server address:

| DNS field        | Example value  |
| ---------------- | -------------- |
| Type             | `A`            |
| Name or host     | `mc-origin`    |
| Value or content | `203.0.113.20` |

Then create the Minecraft Java SRV record:

| DNS field | Example value           |
| --------- | ----------------------- |
| Type      | `SRV`                   |
| Service   | `_minecraft`            |
| Protocol  | `_tcp`                  |
| Name      | `play`                  |
| Priority  | `0`                     |
| Weight    | `0`                     |
| Port      | `25570`                 |
| Target    | `mc-origin.example.com` |

Some DNS providers combine the service, protocol, and name into `_minecraft._tcp.play`. Replace the example address and port with the Purpify values.

<Note>
  If your DNS provider offers an HTTP proxy, CDN, or orange-cloud style proxy, keep the Minecraft record DNS-only unless that provider explicitly supports proxying Minecraft traffic.
</Note>

## Test and troubleshoot

1. Confirm that the server works with its direct Purpify address and port.
2. Save the DNS records and wait for DNS caches to update.
3. Test `play.example.com` from Minecraft Java Edition.
4. If it fails, confirm the SRV name, target, assigned port, and address record.
5. Make sure the SRV target is a hostname with its own address record and does not end at an unconfigured name.

If you move the server later, update the address and SRV records only after the new server works directly.
