How to setup custum url for workers

HI,

I want to use custom domain name URLs for the workers, for www.example.com/test

the deployment will show the content on this custom page.

Please tell me the DNS cname name configuration.

I want to user worker as a reserve proxy.

You’d have to set that as a Workers Route for your domain:

3 Likes

thanks for the reply

That is I already know, what should I fill in the DNS management of the domain i have to configure.

Cname or A name

Name (use @ or root)

Target

I would go with A domain.com and A www records, both pointed to an example 192.0.2.1.

Here is why:

3 Likes

My domain name is working fine, I have to configure a subdomain or URL for my workers.

Here is my DNS setting for workers route
I have just added https://test.unblocksite.info/ URL onto route according to tutorial on a website
https://test.unblocksite.info/

the script is not working on that URL but it’s fine on another deploy without adding a route URL https://delicate-lab-0ff0.fortnite22sharma.workers.dev/

May I know the reason for getting this error?

and how can I get unblocksite.info/test

After connecting domians name to worker script I am getting this error Failed to register a ServiceWorker for scope (‘https://test.unblocksite.info/’) with script (‘https://test.unblocksite.info/sw.js’): A bad HTTP response code (530) was received when fetching the script. Without the domians name it’s working fine on other 2 deploy.

Sorry it’s the problem is fixed.

My above Image for DNS configuration is correct there is some java script is missing in the server l.

I have one last questing what shoud I type in the CNAME decide to get. Example.com/test

A 1xxx error should be returned as a result, and you should search for the specific 1XXX error within the Cloudflare Help Center for troubleshooting information.