Fowarding adding /www. to the END of the domain

I followed the tutorials for forwarding a domain and for some reason it’s adding an extra www. to the END of the old domain when I visit the site. Searched community here and couldn’t find it.

I updated the DNS of the old domain.
Set forwarding to olddomain.com/
Permanent redirect.
https://newdomain.com/$1

The new domain is also on cloudflare.
I have the DNS setup and working on that.

I can’t figure out why it’s adding an extra /www. to the end of the domain. Any ideas?

Thanks!

You’ll be referencing the wrong wildcard and will take the hostname instead of the path. Try $2 instead.

2 Likes

OK thank you!

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.