I have installed an ad blocker app that seems to help my phone. It's not 100%, but does a decent job. The ad blocker app that I use is Blokada and can be downloaded from the "f droid" app store.
I'm not sure if that is what you are asking for, or, if it will even help you.