How to remove ‘Your Mac is infected with 3 viruses’ and other pop-ups from Mac, PC, iPhone or iPad

At last time, more and more users cause troubles with annoying messages in popular browsers: Google Chrome, Mozilla Firefox, Safari or other browsers. These messages, called pop-ups, usually highlights nonexistent problems with Mac, iPhone & iPad; or report about fake information, for example about winning the lottery, e.t.c. All these pop-ups invented for the main purpose: to draw the attention of users to different sponsored offers. For example, pretty notorious pop-up, called Your Mac was infected by 3 viruses, which offers to scan and clean users Mac/iPhone/iPad from viruses. Don't believe it, in fact, all tabs that are opening by clicking on Scan Now link redirects users to download software for MacOS, iOS or Windows.