The fastest way to remove a virus from your phone

If your phone has a virus, the most reliable fix is to back up your photos and documents, then reset the phone to factory settings. This wipes everything — including the virus — and reinstalls the original operating system. On Android, go to Settings > System > Reset options > Erase all data. On iPhone, go to Settings > General > Transfer or Reset > Erase All Content and Settings. After the reset completes, sign back into your accounts and restore your backed-up files from cloud storage.

A factory reset works because viruses live in the phone's software layer. Resetting removes that layer entirely and replaces it with a clean copy. Other methods — like antivirus apps or clearing the cache — may slow a virus down or remove some types of malware, but they often leave traces behind that can reactivate later.

If you cannot back up your files before resetting, or if you want to try removing the virus without erasing everything, there are other steps to take first. But understand that none of them are as thorough as a reset.

Key Takeaways

  • A factory reset removes viruses completely because it replaces your phone's entire operating system with a clean copy from the manufacturer.
  • Back up your photos, documents, and other files to cloud storage before you reset, because the reset will erase everything on the phone.
  • If you do not want to reset, you can try uninstalling suspicious apps, clearing your browser cache, and running a scan with Google Play Protect (Android) or letting Apple scan your phone (iPhone).
  • Viruses often hide in recently installed apps or in browser extensions, so check what you downloaded in the last few days before deciding whether to reset.
  • After you remove the virus, change your passwords on a separate device, because the virus may have captured them while it was on your phone.

Identify which app or browser extension is causing the problem

Before you reset, spend a few minutes looking for the culprit. Most phone viruses arrive through apps you installed yourself — either from the official app store or from a link in an email or text message. Open your phone's app list and look at what you installed in the last week or two. Common disguises include fake antivirus apps, fake updates, games with suspicious names, or apps that ask for unusual permissions (like a flashlight app that wants access to your contacts).

On Android, go to Settings > Apps and look at the "Install date" for each app. On iPhone, go to Settings > General > iPhone Storage and sort by "Last Used" to see recent activity. If you find an app you do not recognize or do not remember installing, that is a strong candidate. Write down the name.

Also check your browser. Open Chrome, Safari, or whatever browser you use and look at the extensions or add-ons. On Android Chrome, tap the three-dot menu > Settings > Extensions. On iPhone Safari, go to Settings > Safari > Extensions. Malicious extensions can inject ads, redirect your searches, or steal data. If you see something unfamiliar, note it.

Uninstall suspicious apps and clear your browser

Once you have identified a likely culprit, uninstall it. On Android, go to Settings > Apps, find the app, tap it, and select Uninstall. On iPhone, go to Settings > General > iPhone Storage, find the app, tap it, and select Offload App or Delete App. Offload removes the app but keeps your data; Delete App removes everything.

Next, clear your browser's cache and cookies. On Android Chrome, tap the three-dot menu > Settings > Privacy > Clear browsing data, then select "All time" and check Cookies and site data and Cached images and files. On iPhone Safari, go to Settings > Safari > Clear History and Website Data. This removes temporary files that a virus may have used to track you or inject code.

After you uninstall and clear the cache, restart your phone. Hold the power button and slide to power off, then turn it back on. This closes any processes the virus was running in the background.

Run a built-in security scan on Android

Android phones come with Google Play Protect, a built-in scanner that checks apps for known malware. Open the Google Play Store app, tap your profile icon in the top right, then tap Manage apps and device > Manage. Scroll to the top and tap Play Protect. Tap Scan to run a full check of your installed apps. If Play Protect finds something, it will show you the app name and offer to uninstall it.

Play Protect is not perfect — it catches common viruses but misses sophisticated ones — but it is a quick step that takes about five minutes. If it finds nothing and your phone is still behaving strangely, move on to a factory reset.

Some Android phones also have a built-in security app from the manufacturer. Samsung phones have Samsung Knox, for example. You can run that scan too, though it usually finds the same things Play Protect does.

Let Apple scan your iPhone

iPhone does not have a built-in antivirus app the way Android does, because Apple controls what apps can do more strictly. However, you can run a check through iCloud. Go to Settings > [Your Name] > iCloud > Keychain and make sure it is turned on. Then go to Settings > [Your Name] > Password & Security and tap Security Recommendations. This scans for compromised passwords and weak security settings.

You can also check for suspicious apps by going to Settings > General > iPhone Storage and looking for apps you do not recognize. Unlike Android, iPhone apps cannot run in the background without your permission, so a virus on iPhone is usually confined to the app itself. If you uninstall the app, the virus goes with it.

If your iPhone is still acting strange after uninstalling suspicious apps and clearing your browser, a factory reset is the next step.

Back up your files before you reset

If you decide to do a factory reset, back up everything you want to keep first. On Android, go to Settings > System > Backup and make sure it is turned on. This backs up your contacts, calendar, and app data to your Google account. For photos and documents, open Google Photos or Google Drive and make sure your files are synced to the cloud.

On iPhone, go to Settings > [Your Name] > iCloud > iCloud Backup and turn it on. This backs up your contacts, photos, messages, and app data. You can also plug your iPhone into a computer and use Finder (Mac) or iTunes (Windows) to create a local backup, though a cloud backup is usually faster and safer.

Wait for the backup to finish — this can take 30 minutes or more depending on how much data you have — before you reset. You can check the progress by going back to the backup settings and looking at the timestamp.

Perform a factory reset

Once your files are backed up, reset your phone. On Android, go to Settings > System > Reset options > Erase all data (or Erase all data on some phones). You will be asked to confirm; tap Erase. The phone will restart and show a setup screen, just like when it was new. This takes 10 to 20 minutes.

On iPhone, go to Settings > General > Transfer or Reset > Erase All Content and Settings. You will be asked to enter your Apple ID password and confirm. The phone will restart and show the setup screen. This also takes 10 to 20 minutes.

When the reset is complete, sign back into your Google account (Android) or Apple ID (iPhone), and restore your backed-up files. The phone will read your contacts, calendar, photos, and apps automatically.

Change your passwords after the reset

Once your phone is clean and restored, change your passwords on a separate device — a computer or tablet that you know is not infected. Start with your email password, because that account controls access to everything else. Then change passwords for your bank, social media, and any other accounts you use on your phone.

A virus can capture passwords while it is running, so assume any password you entered on the infected phone may have been seen. Changing them on a clean device ensures the virus cannot use the old ones to log back in.

You should also check your email and bank accounts for suspicious activity. Look for login attempts from unfamiliar locations, unauthorized transactions, or password reset requests you did not make. If you find anything, contact your bank or email provider right away.

Frequently Asked Questions

Can an antivirus app remove a virus better than a factory reset?

No. Antivirus apps can find and remove some malware, but they cannot access the deepest parts of your phone's operating system the way a factory reset can. A reset is always more thorough because it replaces the entire operating system with a clean copy from the manufacturer.

Will a factory reset delete my photos and messages?

Yes, a factory reset deletes everything on your phone. That is why you must back up your photos, messages, and documents to cloud storage before you reset. After the reset, you can restore them by signing back into your account.

What if my phone is still acting strange after I uninstall the suspicious app?

The virus may have left traces behind, or you may have missed the culprit app. Try clearing your browser cache and running a security scan. If the problem continues, do a factory reset. That is the only way to may provide the virus is completely gone.

How do I know if an app is actually malicious or just poorly designed?

Look at the app's permissions and reviews. Go to the app's page in the Play Store or App Store and read recent reviews — if many people say it is stealing data or showing unwanted ads, it is probably malicious. Also check what permissions it asks for. A flashlight app should not need access to your contacts or location.

Can I get a virus from just visiting a website?

On modern phones, it is very difficult. Android and iPhone both prevent websites from installing apps without your permission. However, a website can trick you into downloading a malicious app by disguising it as a game or update. Never read apps from links in emails, texts, or websites — only from the official Play Store or App Store.