Avast isn't preventing viruses

I installed avast on my macbook about a month ago because i was starting to get viruses and since installing it i’ve had no improvement at all. Every time i click a link i get ps4ux viruses, and i was wondering if i had done anything wrong in the installation. Please help as this is getting out of hand, the viruses just seem to be worst since i’ve installed this software.

  • Close Safari (if you have it open)
  • Hold down the shift key while opening Safari
  • Preferences > extensions : remove all extensions you don’t recognize/want
  • Preferences > Privacy : turn off “extensions created by third party…”
  • Remove all website data (don’t forget to confirm)
  • Preferences > General : make sure the homepage is set to what you want (e.g. https://www.google.com)
  • Select history and delete everything