Redirecting to another site's subfolder/path. Getting 403 Error

mydomain nameservers point to Cloudflare.

I simply want to forward/redirect to
I really do not care about what is going to show in addressbar or even SEO ranking.
The main reason I moved to Cloudflare is using its MX Record settings with my Zoho Mail.
My site is actually hosted in the company website as above and I just want my own domain address for simplicity.
I followed every single help I could find but no luck.
The best I get is below page. Any help will be very appreciated.

Server Error
## 403 - Forbidden: Access is denied.
### You do not have permission to view this directory or page using the credentials that you supplied.

You could either do this on the server, however for that you actually dont even need any server as you can do this via page rules. Simply define one that redirects everything to the destination URL.

1 Like

Thnx, what should I put in DNS records in Cloudflare? (cname, a, etc)
I already did Page URL but something should be wrong, very likely with my DNS records settings.

If you are using page rules the DNS settings are actually pretty irrelevant, you just need the records themselves (assuming the proxy icon is :orange: and not :grey:). Can you post the domain in question and your page rule?

1 Like

Thank you or response.
I want when visitors type (and also with www) in address bar, they they forwarded/redirected to (and also with www)
We have no concern about what is going to show in address bar or page/site SEO. As long as it gets forwarded/redirected, we are happy.
My Page Rule is as below, but currently I have no DNS RECORDS set in Cloudflare. I tried everything from CNAME and A record but none of them worked.
I think my Page Rule is good but I have no idea what to add to DNS RECORDS.

Thats the problem, you need to have them. Assuming you want to redirect the entire domain you can point to anywhere (you can point to if you want). So create an A record for and a CNAME for www pointing to “@” (the naked domain). Your page rule looks alright, except for the trailing plus sign, which should be an asterisk as well.

1 Like

Thanx for your time.
I did as you said and still no luck.

Screenshot below:

I should add $1 to the end of destination link!!

Only if you want to forward whatever the wildcard matches. Do you want that?

No sure what you mean (sorry I am newbie) but yeah, as long as I visitor is taken to destination website, I am Ok.

Now one problem is left.
when I enter, (with www) it forwards to >>
which is not a valid link. Without www everything looks good.

Thats because you added $1. That should not be necessary and actually gives you the result you now have

1 Like

WoW, you are right. I think I rushed a bit. it seems to work! I am so excited! Thnxxxx
Would you please tell me what is the difference between + and * at the end of Page Rule url?
Cloudflare help only talks about adding +

And also diffrenece between 301 and 302 redirect?
Which one is better?

The difference should be the former is not supported :slight_smile: , only the latter. Meaning + is just a plus sign, whereas * is the wildcard.

May I ask where you found that? It would be new to me + has any special meaning in this context.

1 Like

This only talks about the plus sign as plus sign, not as wildcard. I guess because its in a Google Plus context :slight_smile:

1 Like

Oh thnx. I will read both articles.
One more question, please.

httpS:// (with or without www) does not work. Anyway I can fix it?

AFAIK, Cloudflare cant issue HTTPS certificates for .ir domains right now because their CA cant issue them because some Western politicians are not happy with some Iranian politicians (meaning, sanctions :slight_smile: ) - Kindergarten on high levels :wink:

1 Like

I guessed so, anyway just to forward it to http without S just to prevent the error?

You mean the TLS error when you try to access it via HTTPS? That you wont be able to fix because there wont be a certificate for your domain, hence you dont even get the chance to rewrite anything. For that you would need to use a non-ir domain.

1 Like

Thank you so very much. I helped many people in IT with patience and karma got back to me. Thank you and have a wonderful day.