How to get rid of virus on mac

Last Updated: Mar 2, 2024 by

Mac computers are known for their security and reliability, but they are not immune to viruses and malware. With the rise of cyber threats, it is important to know how to protect your Mac and remove any viruses that may have infected it.

In this article, we will discuss how to remove viruses from your Mac and keep it clean and secure.

How Do Macs Get Infected with Viruses?

Contrary to popular belief, Macs can get infected with viruses just like any other computer. However, they are less susceptible to viruses due to their built-in security features and smaller market share compared to Windows computers.

Macs can get infected with viruses through various means, including:

  • Downloading infected files or software from the internet
  • Opening infected email attachments
  • Visiting malicious websites
  • Using infected external devices, such as USB drives
  • Installing pirated software or apps from untrusted sources

Signs of a Virus on Your Mac

If your Mac is infected with a virus, you may experience the following symptoms:

  • Slow performance
  • Frequent crashes or freezes
  • Pop-up ads or unwanted browser extensions
  • Unusual error messages
  • Unexplained changes to your settings or files
  • High CPU usage
  • Unusual network activity

If you notice any of these signs, it is important to take action immediately to remove the virus and prevent further damage to your Mac.

How to Remove Viruses from Your Mac

Step 1: Disconnect from the Internet

The first step in removing a virus from your Mac is to disconnect it from the internet. This will prevent the virus from spreading and downloading additional malware.

Step 2: Boot into Safe Mode

Booting your Mac into Safe Mode will prevent any third-party apps or processes from running, making it easier to remove the virus. To boot into Safe Mode, follow these steps:

  1. Shut down your Mac.
  2. Press the power button to turn on your Mac.
  3. Immediately press and hold the Shift key until the Apple logo appears.
  4. Release the Shift key when you see the login screen.

Step 3: Scan Your Mac for Viruses

Once your Mac is in Safe Mode, you can use an antivirus software to scan for and remove any viruses. Some popular antivirus software for Mac include:


Follow the instructions provided by the antivirus software to scan your Mac and remove any viruses or malware found.

Step 4: Delete Suspicious Files and Apps

If the antivirus software does not detect any viruses, you can manually check for suspicious files and apps on your Mac. Look for any unfamiliar files or apps and delete them. You can also use the Activity Monitor to check for any suspicious processes and force quit them.

Step 5: Clear Your Browser Cache and History

Viruses can sometimes hide in your browser cache and history. To remove them, clear your browser cache and history. Here’s how to do it for popular browsers:

  • Safari: Go to Safari > Clear History and Website Data.
  • Chrome: Go to Chrome > Clear Browsing Data.
  • Firefox: Go to History > Clear Recent History.

Step 6: Reset Your Browser Settings

If clearing your browser cache and history does not remove the virus, you may need to reset your browser settings. This will remove any malicious extensions or settings that may have been added by the virus. Here’s how to reset your browser settings for popular browsers:

  • Safari: Go to Safari > Preferences > Advanced > Show Develop menu in menu bar. Then, go to Develop > Empty Caches.
  • Chrome: Go to Chrome > Settings > Advanced > Reset and clean up > Restore settings to their original defaults.
  • Firefox: Go to Help > Troubleshooting Information > Refresh Firefox.

Step 7: Update Your Operating System and Apps

Keeping your operating system and apps up to date is crucial in preventing viruses and malware. Developers often release updates to fix security vulnerabilities and bugs that can be exploited by viruses. To update your Mac, go to System Preferences > Software Update.

Step 8: Enable Firewall and Gatekeeper

Firewall and Gatekeeper are built-in security features on Mac that can help prevent viruses and malware from infecting your computer. Firewall monitors incoming and outgoing network traffic, while Gatekeeper checks for the validity of apps downloaded from the internet. To enable these features, go to System Preferences > Security & Privacy > Firewall/Gatekeeper.

How to Keep Your Mac Clean and Secure

Install an Antivirus Software

Installing an antivirus software is the first line of defense against viruses and malware. Make sure to choose a reputable and up-to-date antivirus software to ensure maximum protection for your Mac.

Be Cautious When Downloading Files and Apps

Avoid downloading files or apps from untrusted sources. Stick to official app stores and websites to minimize the risk of downloading infected files.

Use a Virtual Private Network (VPN)

A VPN encrypts your internet connection, making it more difficult for hackers to intercept your data. This is especially important when using public Wi-Fi networks, as they are more vulnerable to cyber attacks.

Regularly Back Up Your Data

In case your Mac does get infected with a virus, having a backup of your data can save you from losing important files. Make sure to regularly back up your data to an external hard drive or cloud storage.


Viruses and malware can cause serious damage to your Mac, but with the right knowledge and tools, you can easily remove them and keep your Mac clean and secure. Remember to always be cautious when downloading files and apps, and regularly update your operating system and apps to stay protected. By following these tips, you can ensure that your Mac stays virus-free and runs smoothly.

Gulrukh Ch

About the Author: Gulrukh Ch

Gulrukh Chaudhary, an accomplished digital marketer and technology writer with a passion for exploring the frontiers of innovation. Armed with a Master's degree in Information Technology, Gulrukh seamlessly blends her technical prowess with her creative flair, resulting in captivating insights into the world of emerging technologies. Discover more about her on her LinkedIn profile.