# Webrequest cleanrule does not work

**URL:** <https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680>\
**Category:** Open Q&A\
**Tags:** request-attributes\
**Created:** [March 3, 2023, 7:44am UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680 "2023-03-03T07:44:12Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![henk\_stobbe](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/henk_stobbe/32/30434_2.png) [@henk\_stobbe](https://community.dynatrace.com/u/henk_stobbe)\
**Post date:** [March 3, 2023, 7:44am UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/1 "2023-03-03T07:44:12Z")

</div>

Good morning,

I am trying below cleanup rule:

 ![henk_stobbe_0-1677829237398.png](https://global.discourse-cdn.com/dynatrace/original/3X/4/3/431d926af943491fdf6ca7d5039389ae3a64275d.png)

(also tried %20 without ()), but that also did not work.

Is is a bug or is it a feature?

KR Henk

---

<div class="post-metadata">

**Author:** ![Julius\_Loman](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/julius_loman/32/51_2.png) [@Julius\_Loman](https://community.dynatrace.com/u/Julius_Loman)\
**Post date:** [March 3, 2023, 8:05am UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/2 "2023-03-03T08:05:58Z")

</div>

Maybe escaping the % with a \ ?

---

<div class="post-metadata">

**Author:** ![henk\_stobbe](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/henk_stobbe/32/30434_2.png) [@henk\_stobbe](https://community.dynatrace.com/u/henk_stobbe)\
**Post date:** [March 3, 2023, 8:57am UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/3 "2023-03-03T08:57:39Z")

</div>

Hi Julius,

Thanks for the hint, sorry no luck…

Also tried " " \u0020 , (%)20&nbsp; (-;

KR Henk

---

<div class="post-metadata">

**Author:** ![joseandrescalvo](https://avatars.discourse-cdn.com/v4/letter/j/fbc32d/32.png) [@joseandrescalvo](https://community.dynatrace.com/u/joseandrescalvo)\
**Post date:** [March 3, 2023, 12:57pm UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/4 "2023-03-03T12:57:13Z")

</div>

Hi. Tested %20 as regular expression for clean up and it works.

Anycase, there is no need to include a capture group in regular expresions for cleanup rules: all matching strings are removed.

 ![Screenshot_36.png](https://global.discourse-cdn.com/dynatrace/original/3X/b/4/b478fb6c4dfd3b05bf0c5dbfe738c0e6e62c32a0.png)

---

<div class="post-metadata">

**Author:** ![henk\_stobbe](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/henk_stobbe/32/30434_2.png) [@henk\_stobbe](https://community.dynatrace.com/u/henk_stobbe)\
**Post date:** [March 3, 2023, 1:10pm UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/5 "2023-03-03T13:10:46Z")

</div>

Hello Jose,

Thanks for your reply, need to investigate at my end. This does not work for my envoronment )-;

KR Henk

---

<div class="post-metadata">

**Author:** ![henk\_stobbe](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/henk_stobbe/32/30434_2.png) [@henk\_stobbe](https://community.dynatrace.com/u/henk_stobbe)\
**Post date:** [March 3, 2023, 4:06pm UTC](https://community.dynatrace.com/t/webrequest-cleanrule-does-not-work/38680/6 "2023-03-03T16:06:17Z")

</div>

Hello,

A second look: the %20 is part of a placeholder (URL query),

I created a naming rule adding a “query parameter”. After adding the cleanup rule of %20, you can clearly see that this has no impact on the placeholder

So the solution is simple ,

You create two placeholders one that stops at the %20 and one that starts at %20 (so you split up with the help of the %20)

 ![henk_stobbe_0-1677947647421.png](https://global.discourse-cdn.com/dynatrace/original/3X/5/9/59fe1975c2608012d290fc2fe3e754429108fbdb.png)

Have a great weekend!
