How to Remove Malware from Your iPhone

Understand the warning signs of a virus and how to remove malware from your iPhone.
We receive compensation from the products and services mentioned in this story, but the opinions are the author's own. Compensation may impact where offers appear. We have not included all available products or offers. Learn more about how we make money and our editorial policies.

Although many people believe that an iPhone or iPad is more secure than Android devices, it’s still possible for an Apple device to get a virus. There are several signs that your phone may be infected, including:

  • reduced battery life
  • decreased operating speeds
  • higher than normal data charges
  • unexpected pop-ups
  • suspicious apps or activity

A virus or malware can do more than just slow down your phone's overall performance and use more data — they can compromise your personal information and online accounts, including your digital wallets and financial apps. Although App Store apps are subject to Apple’s high security standards, your iPhone can be infected with a virus from sources such as third-party app stores or a suspicious email or link. 

If you think your phone may have a malware infection, there are simple ways to restore your iPhone and reclaim your security. We'll walk you through the steps, plus show you our recommended best iPhone antivirus apps to help you remove malware and protect against future threats.

In this article
How to remove malware from an iPhone
How to restore your iPhone from an iCloud backup
How to restore your iPhone from a computer backup
How to protect your iPhone from mobile malware
Best antivirus apps to remove and prevent malware
FAQs
Bottom line

How to remove malware from an iPhone

If your phone is infected with spyware, a virus, or other malware, you can remove it using these steps.

1. Restart your iPhone

Restarting the device is your first step to removing iPhone viruses or malware.

Depending on the type of iPhone you have, restarting it will be a little different. If you have an iPhone X, 11, 12, or 13, you need to press and hold the volume up or down button, along with the side button. Hold both of these until “slide to power off” appears. Slide the button and wait 30 seconds for the power to turn off. Once off, turn your iPhone back on by holding the side button until the Apple logo appears.

Slide to power off

For older iPhones, press and hold down the side or top power button until the power-off slider appears.

If your iPhone still has the same issues you noticed before, consider trying these additional steps to secure your device.

2. Clear your browsing data and history

If restarting your iOS device doesn’t clear the virus, you should also try to clear your browsing data and history. Clearing your browsing history depends on what browser you use.

Safari

To clear the data from Safari, you’ll head to the settings icon on your iPhone.

  • Scroll down to the Safari icon and select it.

iPhone screen showing location of Safari icon

  • Find Clear History and Website Data and select it.

iPhone screen showing location of button to clear history and website data in Safari

Google Chrome

If you use Chrome, you’ll head to the app to erase your browsing data and search history.

  • In Chrome, click on the “...” in the bottom right and select history.

iPhone screen showing where to click on history in Chrome

  • Once in the history section, select Clear Browsing Data. This will allow you to define what to delete and in what time frame.

iPhone screen showing what to click to clear browsing data

Mozilla Firefox, Microsoft Edge, and other browsers

For other browsers, head to the settings section and look for the option to erase your history and website data. This practice is also good for your laptop or desktop computer for added security, as well.

How to restore your iPhone from an iCloud backup

Another option to remove malware from your iPhone is to restore your phone to a previous backup from before the virus was installed on your device. To begin the backup process, you want to make sure you have a recent backup saved on your iCloud. If you select to restore your iPhone from an iCloud backup, you’ll sign in to iCloud with your Apple ID and select the backup you’d like to use to restore your phone. Your phone will begin restoring from the backup, which could take from minutes to hours to finalize. Your phone will show a progress bar of the process.

  • To see your latest iCloud backup, go to Settings on your iPhone and select your Apple ID at the top of the settings menu.

iPhone screen showing where to click iCloud in Settings

  • Here you can find the iCloud icon and find your latest backup.

iPhone screen showing where to click on iCloud backup

  • After you select iCloud, you will select iCloud backup. If the backup is turned on, you will see your latest backup displayed.

iPhone screen showing iCloud backup

  • You can also instruct your iPhone to conduct a backup at this time if you need a more recent backup.

The benefit of restoring your iPhone from a backup is that you can go back to an earlier version prior to the virus being on your phone and still keep all of your important contacts, pictures, and more.

Once you’ve verified that you have a recent backup, you will want to begin the restoration process. To begin restoring your phone, you will want to follow the steps to erase all content and settings below.

Erase all content and settings

You’ll need to erase all your content and settings to install a backup version of your iPhone.

This is also an option, even if you don’t have a backup. If your phone has become unusable due to malware, it might be worth it to erase all content and settings, even if you don’t have a backup. This will bring your phone back to its original condition when you purchased it.

Note: Erasing all content and settings will erase all of your content — including contacts, pictures, and more. It’s essentially a factory reset. You’ll need to start from scratch and re-download apps and other items if you don’t have a backup.

To erase all content and settings from your iPhone, follow these steps:

1. Open your device settings.

iPhone settings screen

2. Go to General.

iPhone screen showing where to click on General

3. Scroll down to Transfer or Reset iPhone.

iPhone screen showing where to click on transfer or reset iPhone

4. Select Erase All Content and Settings.

iPhone screen showing where to click on erase all content and settings

5. Follow the on-screen prompts to reset your iPhone. You may need to enter your passcode.

Once the process is complete, it will reboot as if it were a new phone. 

If you have a backup, follow the steps below to restore the backup. Just be sure the backup is from before the malware was installed. If you don’t have a backup, you’re starting fresh and will need to manually download all your apps.

How to restore your iPhone from a computer backup

Once you’ve erased all the content on your iPhone, turn the device on to start restoring the backup. When you turn on the iPhone, you’ll follow the prompts until you get to the Apps & Data section. You can select to restore your phone from an iCloud backup or from a Mac or PC.

Restoring from a Mac running macOS Catalina

If you’d like to restore your iPhone from a backup on your Mac running macOS Catalina, you can also do that after erasing the content and settings. Similar to the iCloud backup, you’ll follow on-screen prompts until you get to the Apps & Data section of starting your iPhone. Here you can select to restore from a Mac.

If your backup is encrypted, you’ll need to enter the password to the backup to begin the process.

If you’re running macOS Catalina or a later operating system, you’ll complete the restore process through Finder. Open Finder and connect your iPhone with a USB cable. From here, select your iPhone from the finder window. Once you’ve selected your device, you can select “Restore Backup” to begin the process.

Similar to restoring from iCloud, you’ll select the backup you’d like to use and begin the restore process.

Restoring from a PC or earlier version of macOS

If you’re using a PC or a Mac with an earlier version of the operating system, you’ll use iTunes to complete the restoration process. To start, open iTunes and plug your iPhone into your computer using a USB cable.

From iTunes, you’ll be able to see the iPhone. Select the iPhone from the menu on the left and choose “Restore Backup” to begin the process. Select the backup you’d like to use and select restore.

How to protect your iPhone from mobile malware

It’s important to take steps to protect your iPhone and other devices from malware. The same security tips you practice for your laptop or desktop device will help avoid unwanted files on your iPhone as well.

Here are a few security measures to keep iPhone malware at bay:

  1. Don’t open files from unknown sources. You may receive text messages from unknown phone numbers that include a link to a file or even an actual file. These could be a scam or hackers attempting to get your information, and links could lead you to a phishing site. To avoid a virus, don’t click on suspicious links or open files from anyone you don’t know.
  2. Avoid apps you don’t remember downloading. If you see unfamiliar apps on your phone that you don’t remember downloading, consider deleting them. And only download apps from the App Store to avoid putting malicious apps on your device. 
  3. Watch out for in-app ads. There are many apps out there that include in-app ads. These ads may link to an unwanted website. Avoid clicking on in-app ads that look suspicious or that you don’t recognize.
  4. Keep iOS up-to-date. Apple will periodically update iOS software. Many of these software updates have patches for iPhone vulnerabilities. Update your iPhone promptly when these are released.
  5. Avoid jailbreaking your device. Jailbreaking, or removing security features to gain access to the operating system, can decrease the security of your jailbroken device and could lead to more opportunities for malware.
  6. Encrypt your backup. To further protect your data and device, add encryption to your iPhone backups. This will add an extra layer of protection to the backup so you can restore your iPhone knowing that the backup data was secure.
  7. Use a VPN. Using a virtual private network (VPN) is another way to keep your iPhone safe while browsing the internet, especially when you’re using public Wi-Fi. This will hide your IP address and help secure your browsing history. We recommend NordVPN as the best VPN for iPhones.

Customizable Coverage That is Simple to Use
5.0
Editorial Rating
Learn More
On NordVPN's website
VPN
NordVPN
Up to 72% off + 3 months extra
  • #1 rated VPN with over 6,800 ultra-secure, high-speed servers in 111 countries
  • Reliably unblock popular streaming services like Netflix with a single click
  • Excellent all-in-one security product with antivirus, ad blocker, password manager, and more

Best antivirus apps to remove and prevent malware

In addition to the safety tips above, there are several good antivirus programs you can install to protect your iPhone and get rid of viruses. We've tested dozens of antivirus programs that help clear viruses and other threats. Check out our top picks for the best antivirus apps for iPhone.

  • Norton 360: Norton's iPhone antivirus app is loaded with security features, making it a great value choice. We especially like that it automatically scans for the latest security patches and updates, and it includes phishing protection for your iCal and text messages.

    See Norton Plans | Read Our Norton Review
  • Avast: We love Avast's free antivirus app for mobile security, as it doesn't try to cut corners despite you not paying a dime. Avast Premium Security comes with extras to ensure you can shop, bank, and make online payments through your phone without worrying about hackers or scammers.

    See Avast Plans | Read Our Avast Review
  • McAfee: McAfee's dedicated iPhone app helps you catch system vulnerabilities before they're too late. Additionally, it provides identity protection by monitoring your Social Security number, bank account information, and up to 10 email addresses. These features can keep your data secure and private.

    See McAfee Plans | Read Our McAfee Review

Enjoy Norton’s 100% Virus Protection Promise
4.8
Editorial Rating
Learn More
On Norton 360 Antivirus's website
Antivirus Software
Norton 360 Antivirus
Save up to 58% your first year
  • Excellent protection against malware, ransomware, and hacking with perfect test results
  • Full security suite available to protect every aspect of your digital life
  • Protect with confidence thanks to their 100% virus removal guarantee

FAQs


+

Can an iPhone be infected with malware?

Yes, iPhones and iPads can be infected with malware. Apple does have a strict vetting process for new apps and also has enhanced security standards. However, iPhones can still get a virus from unsafe links or apps.


+

How do you know if you have a virus on your iPhone?

There are a few signs that your iPhone may have a virus, including

  • Suspicious apps on your phone
  • Higher than normal data usage
  • Slow running speeds
  • Battery dying quickly

+

Should you get antivirus protection for your iPhone?

Although Apple’s software is secure, antivirus software could give you an added layer of protection from any viruses. There is a variety of antivirus software available that will protect your iPhone and other devices.

Bottom line

It’s always better to be safe than sorry when protecting your personal data and your devices. Keyloggers, ransomware, and other types of malware can leave your devices vulnerable. Remember, the data on your smartphone is only as secure as the device, and most people fail to protect their iPhones. 

To better protect your iPhone and other internet-connected devices, be aware of the signs of a virus, such as a drastically reduced battery life, decreased operating speeds, unusual data charges, unexpected pop-ups, or suspicious apps or activity. It's also a good idea to add another layer of protection. We recommend a secure VPN with antivirus for ultimate iPhone protection.

Comprehensive Protection With Database Updates Every 3 Hours
4.7
Editorial Rating
Learn More
On Surfshark Antivirus's website
Antivirus Software
Surfshark Antivirus
WINTER DEAL: Up to 86% off + 4 months extra
  • Powerful app that offers 24/7 virus and malware protection that won’t hog your CPU or RAM
  • Includes webcam protection, fully customizable security, full or quick scans, and more
  • Compatible with Windows, Mac, and Android on unlimited devices

Author Details
Andrew Strom Adams is a freelance writer focused on online privacy and digital security. He writes on various topics to help individuals protect themselves on the internet. Andrew has worked in legal marketing, technology, and startups. He has more than 12 years of experience in marketing and communications. He holds an M.B.A. from Westminster College and a B.A. in journalism from Oklahoma Baptist University. When he’s not writing, he’s playing with his two kids or watching reality TV.
Kate is an Editor at All About Cookies. She has 8+ years of digital publishing experience as a content manager, developmental editor, and curriculum writer. She leverages specializations in EdTech and educational publishing to create impactful, well-researched content that aids learners of all ages.