How to get rid of pop-up on iPhone?

In the last week I've been getting annoying pop-ups on safari. It's not on one particular website but just at random times. It gets very annoying and IIm afraid there's a virus on my phone (if that s possible). The pop-up is from mob free click and it tells me to download an app (which I didn't) to continue to the website I want to go on. How should I remove this pop-up?

Close out of Safari completely. (Restart the phone if you aren't able to verify that it's closed, by powering off and back on.) With the app closed, if you go into settings then Safari there's an option at the bottom to clear history and website data. Do that and the issue should go away.