<%NUMBERING1%>.<%NUMBERING2%>.<%NUMBERING3%> PRTG Manual: Regular Expressions

For some sensors (for example, some HTTP sensors and email sensors), you can use regular expressions to match a search pattern. PRTG supports <%P_PCRE%>.

icon-forbidden-redPRTG does not support <%P_REGEX%> options or <%P_REGEX%> flags like, for example, /g (global), /s (single line), or /gs, and will not correctly search for the target string if you try to set options.

See below for examples with the most common patterns and an example for possible matches.

Common Search Patterns

Find matches containing the word error or alarm:


Find matches containing the words error and alarm, in any order:


Find matches containing all of the words tree, flower, leaf, and bug, in any order:


icon-i-round-redIt is not possible to match an empty string using the PRTG <%P_REGEX%> search with sensors.


The search pattern


matches the following expressions:

  • Alarm error
  • Error alarm
  • I am an error and I evoke an alarm.
  • I am an alarm and I indicate an error.
  • An alarm combined with an error indeed!
  • An error combined with an alarm, too!


Regex101: Test and debug your regular expressions

Regex Tester: Test Regular expressions interactively

Wikipedia: Regular expression


Advanced Topics