Edit on val.town ↗

Custom domains

Custom domains allow you to serve HTTP vals from your own domain name(s). Instead of deploying your website on acme.val.run, for example, you can serve it from acme.dev.

Custom domains are available for Pro & Business subscribers, but custom subdomains are available on Free accounts.

The custom domains feature works with domains that you already own, and connects them to your val, which serves all traffic to the domain. You'll need to configure DNS settings with your domain registrar to make this work.

You can buy your domain at any registrar, for example:

Once you have a domain, navigate to Val Town's custom domain settings and add the domain that you want to redirect to one of your vals.

Then choose a val to handle requests to that domain.

Lastly, you'll need to configure the DNS settings in your domain registrar so that requests are routed to your val. We provide a summary of the information below on the domain page for your convenience.

The DNS configuration will depend on the type of domain, apex domains (example.com) or subdomains (something.example.com). These settings will depend on the platform you use to manage your domains.

Note: DNS changes can take up to an hour to take effect.

Create a CNAME record to domains.val.run.:

CNAME record value
something.example.com. domains.val.run.

Replace something.example.com. with your domain. In some domain platforms, you should only use the subdomain, which would be something in the example above.

Create the following two A records:

A record value
example.com. 75.2.96.173
example.com. 99.83.186.151

Replace example.com. with your domain. In some domain platforms, you should replace example.com. with @.

Some registrars, such as Cloudflare, support CNAME records for apex domains as well.

Unfortunately, custom domains can take minutes or hours to propagate, which is quite frustrating because you don't know if you just need to wait or if your settings are incorrect. Even worse, the domain settings can be cached in multiple places, including some outside of your control, including your local network. So if you check your custom domain too early, then you'll continue to not see it working, even when it's properly working on systems that don't have it cached. (If we had a dollar every time a user sent us a message asking for help getting their custom domain working, and when we checked it was already working, we'd have almost ten dollars.)

In other words, use our DNS Debugger to see if your custom domain is correctly set up.

Val Town custom domains are powered by SaaS Custom Domains.

Last updated