Can Mac Get Virus From Website

While many believe that Macs are immune to viruses, that’s not true. A Mac can get viruses from websites just like any other computer. Apple builds security protections into macOS to protect its machines, but they cannot stop all online threats.

 

Here are some of the biggest myths and facts on how MacBooks and Mac desktops can be infected while browsing the internet:

Myths

Facts

Macs are immune to viruses, so there’s no need to use antivirus software on them.Macs can be infected with viruses and malware just like any other computer.
Only malicious websites contain viruses that can infect your Mac.Any website, even legitimate ones, could contain malicious code if it has been hacked.
You have to download files to get a virus on your computer, so just visiting a potentially unsafe website isn’t a problem.Simply visiting a dangerous website is enough to infect your Mac, thanks to much more sophisticated viruses that are widely used today.
Your Mac’s built-in security protections will block all malware and viruses before they can do damage to your machine.Hackers are always finding new ways to circumvent built-in security protections and hide their malicious code, and no antivirus software can detect 100% of all viruses.

If you’ve ever wondered can Macs get viruses while browsing the internet, the answer is yes.

 

The number of infections designed for macOS has steadily increased over time as the OS has become more popular, which means it’s important to protect yourself no matter what you do online. Even legitimate websites can be hacked to send out malicious code.

 

Before we begin:

 

You can protect your Mac from viruses and remove malware by using MacKeeeper’s Antivirus. It works in real-time to identify and block potential threats as soon as they appear, keeping your Mac and all your data safe. Here’s how to get started:

  1. Download MacKeeper and install it on your computer.
  2. When MacKeeper opens, select Antivirus in the sidebar.
  3. Click Launch Antivirus and enter your Mac’s password when prompted.
  4. Click Next then select Start Scan to check for malware on your device.
  5. If a virus is found, click Move to Quarantine to block and delete it.

How Mac can get viruses from websites

There are a number of ways a Mac can pick up viruses when browsing websites online, the most common of which are through exploit kits and website vulnerabilities.

1. Exploit kits

Exploit kits have become one of the most widespread online threats due to the fact that they’re almost entirely automated and can be executed silently without a user knowing. Hackers use compromised websites to divert traffic to their malicious code, which then infects a user’s system. Once inside, the kit can install malware, ransomware, and other nasty threats.

 

A recent example of this is the HanJuan exploit kit that surfaced in 2015, which uses fake ads and shortened URLs to redirect unsuspecting users to malicious sites. It takes advantage of vulnerabilities in software like Internet Explorer to evade antivirus protections, and it can be used to inject viruses, password stealers, and other dangerous software onto a machine.

2. Website vulnerabilities

Website vulnerabilities are flaws, bugs, or other weaknesses in a website’s HTML code that hackers can use to gain unauthorized access. Once inside, attackers may be able to steal sensitive user information, or they may be able to hack the site to distribute malicious code. Many believe that only malicious websites are dangerous, but that’s not always the case.

 

For example, a vulnerability in the gaming platform Steam, discovered in 2017, allowed for an attack called cross-site scripting (XSS). Attackers could use this to inject malicious scripts into the application, allowing them to steal login information, use funds on other user’s Steam accounts, and even spread malicious software using an auto-download file.

Why some websites have viruses

There are many reasons why websites have viruses, such as bugs or flaws in their code, and out-of-date technologies that allow attackers to exploit them. Some websites, such as those offering pirated content, are more likely to host viruses because of the nature of the service they offer. Be careful.

 

Other reasons include:

  • Failing to install updates or improve website code
  • Fake or malicious ads and pop-ups
  • Hijacked links that redirect a visitor to malicious sites
  • Allowing users to distribute their own files that could be dangerous

How to protect your Mac from viruses on websites

Now you know that you can get a virus by visiting a website on Mac, let’s look at how you can protect your Mac to prevent or remove them. Here are the most effective methods:

  1. Keep your system and software up-to-date
  2. Avoid questionable websites
  3. Use web browser default configurations
  4. Enable the pop-up blocking in your web browser
  5. Use antivirus software

1. Keep your system and software up-to-date

To set your Mac to download software updates automatically, follow these steps:

  1. Open System Settings on your Mac.
  2. Click General in the sidebar, then select Software Update.
  3. Next to Automatic Updates, click the i icon.
  4. Enable Check for updates and Download new updates when available.
  5. To install new updates automatically, enable Install macOS updates.
  6. Click Done.
System Settings on Mac shows the General menu. Click Software Update to enable automatic updates.
Step 1. In System Settings, click General then Software Update
System Settings on Mac shows the Software Update menu. Click the i icon to change automatic update settings.
Step 2. Click the i icon
System Settings on Mac shows the Software Update menu. To turn on automatic updates, enable Download new updates when available.
Step 3. Enable Download new updates when available

Updating macOS and the software you use is the best way to ensure they contain no bugs or flaws that could be exploited by hackers. You can set your Mac to download software updates automatically, while apps can be updated through the Mac App Store or within the app itself.

2. Avoid questionable websites

To avoid a Safari virus from unsafe websites, you can practice these safe browsing tips:

  • Check URLs carefully to ensure you’re visiting legitimate sites.
  • If a browser tells you a website is unsafe, leave it.
  • Don’t click on links sent to you by email or text.
  • Don’t click on suspicious ads or pop-ups.
  • If a website you know doesn’t look right, don’t trust it.

3. Use web browser default configurations

Every web browser has default configurations that are designed to keep you as safe as possible online. Some people like to change the default settings without realizing that some alterations can have a negative impact on browser security.

 

To reset Safari back to its default configuration, follow these steps:

  1. Open Safari, then click Safari > Settings in the menu bar.
  2. Click the Extensions tab.
  3. Select any Extensions you don’t recognize or need, then click Uninstall.
  4. Click the Privacy tab, then select Manage Website Data.
  5. Select the Remove All button, then confirm.
  6. Click the Advanced tab, then enable Show features for web developers.
  7. Select Develop > Empty Caches in the menu bar.
The menu bar on Mac shows the Safari menu. Click Settings to access the settings menu.
Step 1. In the menu bar, select Safari > Settings
Safari on Mac shows the settings menu. Click Extensions, then select an extension and click Uninstall to remove it.
Step 2. In Extensions, Uninstall any extensions you don’t need
Safari on Mac shows the Privacy settings menu. Click Manage Website Data to delete all website data
Step 3. In Privacy, click Manage Website Data
Safari on Mac shows the Manage Website Data menu. Click Remove All to delete all website data.
Step 4. Click Remove All to delete all website data
Safari on Mac shows the Advanced settings menu. Enable Show features for web developers to access the Develop menu.
Step 5. In Advanced, enable Show features for web developers
Safari on Mac shows the Develop menu in the menu bar. Click Empty Caches to remove all cache data.
Step 6. In the menu bar, click Develop > Empty Caches

Note from our team: It’s not possible to restore Safari’s default settings with a single button, unfortunately, but the steps above will remove all website data and third-party extensions, leaving you with a fresh Safari as much as possible. Similar steps can be performed inside third-party browsers like Google Chrome, but it may be easier to uninstall and then reinstall them instead for a default setup.

4. Enable the pop-up blocking in your web browser

Most modern browsers have the ability to block pop-ups that can be used to spread malicious software—one of the most common ways you can get a virus on your Mac from viewing a website.

 

Here’s how to do that in Safari:

  1. Open Safari, then click Safari > Settings in the menu bar.
  2. Select the Websites tab, then click Pop-up Windows.
  3. Next to When visiting other websites, select Block and Notify.
The menu bar on Mac shows the Safari menu. Click Settings to access the settings menu.
Step 1. In the menu bar, click Safari > Settings
Safari on Mac shows the Websites settings menu. Click Pop-up Windows, then select Block and Notify to block all website pop-ups.
Step 2. Click Pop-up Windows, then select Block and Notify

You can also block settings in other web browsers like Google Chrome, Microsoft Edge, and Firefox, and in many cases, this feature will be enabled by default. If not, the instructions are similar to those listed above.

5. Use antivirus software

One of the best and most effective ways to get rid of a trojan virus and stop malicious software from infecting your Mac is to use antivirus software. We recommend using MacKeeper Antivirus to protect your machine.

  1. Download MacKeeper on your Mac using the official installer.
  2. When MacKeeper opens for the first time, select Antivirus in the sidebar.
  3. Click the Launch Antivirus button, then enter your password when prompted.
  4. Once the Antivirus is enabled, click Next.
  5. You can now click Start Scan to check your Mac for infections, or click the Enable button to activate real-time antivirus monitoring, which is recommended.
  6. After clicking Enable, select Open Preferences.
  7. Click the lock at the bottom of the window, then enter your password to change settings.
  8. Click the Allow button to give MacKeeper’s Antivirus permission to run.
  9. You also need to give MacKeeper full disk access so that it can find any malicious software no matter where it’s located. To do this, open System Settings, then select Privacy & Security.
  10. Select Full Disk Access, then click the toggles next to MacKeeper and MacKeeper Real-time Protection to enable them.
MacKeeper on Mac shows the main window. Select Antivirus in the sidebar to enable it.
Step 1. In MacKeeper, select Antivirus
MacKeeper on Mac shows the Antivirus window. Click Launch Antivirus to begin the setup process.
Step 2. Click Launch Antivirus to continue
MacKeeper on Mac shows the Antivirus window. Once Antivirus is enabled, click the Next button.
Step 3. Once Antivirus is enabled, click Next
MacKeeper on Mac shows the Antivirus window. To turn on real-time protection, click the Enable button.
Step 4. To use real-time protection, click Enable
MacKeeper on Mac shows the Antivirus window. Click the Open Preferences button to continue enabling real-time protection.
Step 5. Click Open Preferences
System Settings on Mac shows the Security & Privacy menu. To run MacKeeper Antivirus, click the lock button, then click Allow.
Step 6. Click the lock button, then click Allow
System Settings on Mac shows the Privacy & Security menu. Select Full Disk Access to give MacKeeper Antivirus the permissions it needs to find malware on your Mac.
Step 7. Go to System Settings > Privacy & Security > Full Disk Access
System Settings on Mac shows the Full Disk Access menu. Enable all MacKeeper apps to use real-time antivirus protection.
Step 8. Enable both MacKeeper apps

Keeping your Mac free from viruses

Although viruses are a very real threat on Mac, just like they are on other computers, it’s not difficult to keep your machine protected and safe when you’re online. You can avoid picking up viruses from websites by not clicking suspicious links, blocking pop-ups, and avoiding sites that are identified as unsafe by your browser.

 

The best way to protect your Mac is to use antivirus software, like MacKeeper’s Antivirus. It can find hidden threats and remove them from your system, and it identifies new risks in real-time so that they can be stopped before they can cause any harm to your Mac or its data.

Use your Mac to the fullest! Sign up and get:
Effective tips on how to fix Mac issues
Reliable advice on how to stay safe online
Mac-world news and updates

Thank you!

You’ll love exploring your Mac with us.

Oops, something went wrong.

Try again or reload a page.

Here’s another sign you need to upgrade your macOS ASAP:

30% off your MacKeeper subscription

Сopy the code now and use it in the MacKeeper checkout after the upgrade.

Copy Code

Please be aware that this code cannot be combined with any other discounts, offers, or promotions.

Contents

Unlocked
PC

MacKeeper - your all-in-one solution for more space and maximum security.

Try Now

Read more

Is Mac Clean Plus a Virus
Is Mac Clean Plus a Virus
How to Remove Flash Player Virus from Mac
How to Remove Flash Player Virus from Mac
arrow

Run Application

step_1

Click Continue

step_2

Click Install

step_1

Your macOS version is lower than OS 10.11. We’d like to offer you MacKeeper 4 to solve the cleaning, privacy, and security issues of your macOS.