Cache is not being purged for encoded URLs characters (like Arabic slug...)


I see that when the page URL is encoded (Like if the URL in the Arabic language), then Cloudflare can’t purge the cache for this URL. So, what I do is that I use this tool: to decode the encoded URL and purge it on Cloudflare.

  1. Example of encoded URL (Cloudflare can’t purge its cache):

  2. Example of the same URL but decoded (this can be purged with Cloudflare):انشاء-موقع-الكتروني/

I see this bug for a year and was hopping to be fixed day by day… Its very annoying for our ar websites.

Please investigate and tell me if there are any proper solution.

Do you have Normalise Incoming URLs enabled?

I suspect @smarsh is the best person to give a definitive answer here, but could you try converting the percent encoded representations to UPPER case.

1 Like


I can’t, Because in the Arabic language, there is no UPPER and Lower cases.

@smarsh Can you look into this please?

I mean the % encoded characters, your example above would become:

This is impossible and will make the URL broken (different one!).

It can be solved if I used a tool to decode it but this is annoying. We need a solution on the Cloudflare side to make these Arabic and I guess Chinese URLs being purged without the need to decode manually.

Percent encoding is not case sensitive, as per the RFC:

The uppercase hexadecimal digits ‘A’ through ‘F’ are equivalent to the lowercase digits ‘a’ through ‘f’, respectively. If two URIs differ only in the case of hexadecimal digits used in percent-encoded octets, they are equivalent. For consistency, URI producers and normalizers should use uppercase hexadecimal digits for all percent-encodings.

My thinking here is that the Cloudflare Cache may be normalising to a particular form, but the Purge may not perform the same normalisation.

let’s turn on Normalize Incoming URLs and try again :grinning:
credit to @michael


Hi @akrivit,

Great! It worked after I also enabled “Normalized to origin”:slight_smile: Thanks a lot for your help you saved a lot of my time.

Thanks all for help…

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