{"id":21680,"date":"2026-11-20T10:36:00","date_gmt":"2026-11-20T07:36:00","guid":{"rendered":"https:\/\/sunucun.com.tr\/blog\/?p=21680"},"modified":"2026-11-20T10:36:00","modified_gmt":"2026-11-20T07:36:00","slug":"wordpress-malware-removal","status":"publish","type":"post","link":"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/","title":{"rendered":"WordPress Malware Removal: Step-by-Step Guide"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_90 ez-toc-wrap-center counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<span class=\"ez-toc-title-toggle\"><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#Signs_That_Your_Site_Is_Infected\" >Signs That Your Site Is Infected<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#1_Contain_the_Situation_First\" >1. Contain the Situation First<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#2_Do_You_Have_a_Clean_Backup\" >2. Do You Have a Clean Backup?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#3_Scan_the_Files\" >3. Scan the Files<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#4_Reinstall_WordPress_Core\" >4. Reinstall WordPress Core<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#5_Clean_Plugins_and_Themes\" >5. Clean Plugins and Themes<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#6_Check_the_Database_and_Users\" >6. Check the Database and Users<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#7_Renew_the_Security_Keys\" >7. Renew the Security Keys<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#8_Remove_the_Google_Warning\" >8. Remove the Google Warning<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#Preventing_Reinfection\" >Preventing Reinfection<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#Frequently_Asked_Questions\" >Frequently Asked Questions<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#Does_a_security_plugin_remove_the_malware_completely\" >Does a security plugin remove the malware completely?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-13\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#The_site_was_reinfected_after_cleaning_Why\" >The site was reinfected after cleaning. Why?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-14\" href=\"https:\/\/sunucun.com.tr\/blog\/wordpress-malware-removal\/#Why_did_my_hosting_provider_suspend_the_site\" >Why did my hosting provider suspend the site?<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<p><strong>WordPress malware removal<\/strong> is the process of cleaning malicious code, backdoors and unauthorised users from a compromised WordPress site and making it secure again. The most common signs are visitors being redirected to other sites, Google&#8217;s &#8220;This site may be hacked&#8221; warning or a malicious file notice from your <a href=\"https:\/\/sunucun.com.tr\/hosting\/\" data-internallinksmanager029f6b8e52c=\"126\" title=\"Web bar\u0131nd\u0131rma paketlerini inceleyin\">hosting<\/a> provider.<\/p>\n<p>In this guide we explain step by step how to clean an infected WordPress site and how to prevent it from being infected again.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Signs_That_Your_Site_Is_Infected\"><\/span>Signs That Your Site Is Infected<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li>Visitors, especially on mobile or arriving from Google, being redirected to unrelated sites<\/li>\n<li>Pages you don&#8217;t recognise in Google search results (e.g. pharma, gambling or Japanese spam pages)<\/li>\n<li>A security warning in the browser or in Search Console<\/li>\n<li>Users you don&#8217;t recognise in the admin dashboard<\/li>\n<li>Unknown PHP files in the root directory or in <em>wp-content\/uploads<\/em><\/li>\n<li>An unexplained increase in server resource usage or an abuse notice from your hosting provider<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"1_Contain_the_Situation_First\"><\/span>1. Contain the Situation First<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ol>\n<li>If possible, put the site into maintenance mode or take it offline temporarily.<\/li>\n<li>Take a full backup of its current state (even though it&#8217;s infected); you may need it for investigation.<\/li>\n<li>Change the hosting panel, FTP\/SFTP, database and all WordPress administrator passwords.<\/li>\n<\/ol>\n<h2><span class=\"ez-toc-section\" id=\"2_Do_You_Have_a_Clean_Backup\"><\/span>2. Do You Have a Clean Backup?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>If you have a clean backup from <strong>before<\/strong> the attack, restoring it is the fastest solution. After restoring, don&#8217;t forget to update the plugin or theme that caused the vulnerability and to change your passwords; otherwise the site will be compromised again shortly.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"3_Scan_the_Files\"><\/span>3. Scan the Files<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li><strong>Hosting scanner:<\/strong> if cPanel has Imunify360 or a similar scanner, start a full scan.<\/li>\n<li><strong>Security plugin:<\/strong> use a plugin such as Wordfence to compare core files with the originals and scan for malicious code.<\/li>\n<li><strong>Manual check:<\/strong> look at recently modified files. If you have SSH access, <code>find . -name \"*.php\" -mtime -7<\/code> lists PHP files changed in the last 7 days.<\/li>\n<li><strong>Suspicious code:<\/strong> <code>eval(<\/code>, <code>base64_decode(<\/code>, <code>gzinflate(<\/code> and long meaningless strings are common signs. Not every piece of code using these functions is malicious; review carefully.<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"4_Reinstall_WordPress_Core\"><\/span>4. Reinstall WordPress Core<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ol>\n<li>Back up your <em>wp-config.php<\/em> file and your <em>wp-content<\/em> folder.<\/li>\n<li>Delete the <em>wp-admin<\/em> and <em>wp-includes<\/em> folders and replace them with a clean copy of the same version downloaded from WordPress.org.<\/li>\n<li>Replace the core files in the root directory (index.php, wp-login.php, etc.) with clean copies too.<\/li>\n<li>Open <em>wp-config.php<\/em> and check for lines of code you don&#8217;t recognise.<\/li>\n<\/ol>\n<h2><span class=\"ez-toc-section\" id=\"5_Clean_Plugins_and_Themes\"><\/span>5. Clean Plugins and Themes<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li>Delete unused plugins and themes completely.<\/li>\n<li>Reinstall the ones you use with clean copies downloaded from official sources.<\/li>\n<li>If you use nulled (cracked) themes or plugins, remove them; these files are a frequent source of infection.<\/li>\n<li>There should be no PHP files in <em>wp-content\/uploads<\/em>; review and delete any you find.<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"6_Check_the_Database_and_Users\"><\/span>6. Check the Database and Users<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ul>\n<li>Delete administrator accounts you don&#8217;t recognise under <em>Users<\/em>.<\/li>\n<li>Look for hidden links or scripts injected into post and page content.<\/li>\n<li>Check that the <em>siteurl<\/em> and <em>home<\/em> values in the <em>wp_options<\/em> table are correct.<\/li>\n<li>Always take a backup before database operations.<\/li>\n<\/ul>\n<h2><span class=\"ez-toc-section\" id=\"7_Renew_the_Security_Keys\"><\/span>7. Renew the Security Keys<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Replace the security keys (salts) in <em>wp-config.php<\/em> with new values from WordPress&#8217;s key generator service. This ends all open sessions and stops the attacker from logging in with stolen session cookies.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"8_Remove_the_Google_Warning\"><\/span>8. Remove the Google Warning<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Once the site is clean, check the <strong>Security issues<\/strong> report in Google Search Console and submit a <strong>Request review<\/strong>. If spam pages were indexed, those URLs should return 404 or 410; you can speed up the process with the removals tool.<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Preventing_Reinfection\"><\/span>Preventing Reinfection<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<ol>\n<li>Update WordPress, themes and plugins regularly.<\/li>\n<li>Install a <a href=\"https:\/\/sunucun.com.tr\/blog\/best-wordpress-security-plugins\/\">WordPress security plugin<\/a> and turn on two-factor authentication.<\/li>\n<li>Use strong, unique passwords; store them in a password manager, not in the browser.<\/li>\n<li>Take automatic backups stored off the server.<\/li>\n<li>Set file permissions correctly (usually 644 for files and 755 for folders).<\/li>\n<li>Choose hosting that offers server-level malware scanning.<\/li>\n<\/ol>\n<h2><span class=\"ez-toc-section\" id=\"Frequently_Asked_Questions\"><\/span>Frequently Asked Questions<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<h3><span class=\"ez-toc-section\" id=\"Does_a_security_plugin_remove_the_malware_completely\"><\/span>Does a security plugin remove the malware completely?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>It can find and clean known malicious code, but it may not always catch hidden backdoors. Replacing core and plugins with clean copies is more reliable.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"The_site_was_reinfected_after_cleaning_Why\"><\/span>The site was reinfected after cleaning. Why?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Usually a backdoor was left behind or the plugin that caused the vulnerability wasn&#8217;t updated. Make sure you changed all passwords and security keys.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Why_did_my_hosting_provider_suspend_the_site\"><\/span>Why did my hosting provider suspend the site?<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Because malicious files can affect other sites and the server&#8217;s reputation, hosting providers may temporarily restrict infected accounts. After cleaning, you can let the support team know and ask for the account to be reopened.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>WordPress malware removal is the process of cleaning malicious code, backdoors and unauthorised users from a compromised WordPress site and making it secure again. The most common signs are visitors being redirected to other sites, Google&#8217;s &#8220;This site may be hacked&#8221; warning or a malicious file notice from your hosting provider. In this guide we&hellip;<\/p>\n","protected":false},"author":1,"featured_media":21681,"comment_status":"","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"footnotes":""},"categories":[1525],"tags":[],"class_list":["post-21680","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-siber-guvenlik"],"_links":{"self":[{"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/posts\/21680","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/comments?post=21680"}],"version-history":[{"count":1,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/posts\/21680\/revisions"}],"predecessor-version":[{"id":21942,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/posts\/21680\/revisions\/21942"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/media\/21681"}],"wp:attachment":[{"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/media?parent=21680"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/categories?post=21680"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sunucun.com.tr\/blog\/wp-json\/wp\/v2\/tags?post=21680"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}