A certain app I use gives me crucial notifications that I need, but also notifies me almost daily that over 80% of my RAM is used. I would like to allow this app to send me all notifications except those that contain the string "80% of your RAM" in the text of the notification.

Obviously, there is no way to filter a certain app's notifications in stock Android (other than blocking all of a certain app's notifications, but that's not what I want!), but is there a way that I can block notifications if they contain a certain string of text?

Nexus 6P running Android Marshmallow 6.0.1, if you're curious the app in question is CM Security.


If your Android is rooted and has Xposed Framework installed, then NotifyClean xposed module can be used to easily achieve the goal. I have mentioned its relevant usage here.

For non-rooted Android devices, I suggest you use MacroDroid or a similar app, such as Automate.

MacroDroid defines a set of trigger(s), action(s) and constraint(s) as a macro. You must enable Notification access permission and Usage Access permission in it.

You would be needing the following macro.

  • Trigger: Notification → Notification Received:

    • From: choose your app
    • Text Content: here's where you can play. Choose Contains or Matches to filter your text specific notification.
  • Action:

    • Clear Notifications → Select Application(s) → select your app → provide the filtering details again
  • Constraints: none

Save the macro and you're good to go.

Note: MacroDroid can remove sticky/persistent notifications only in Android Oreo and above.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.