whole my website is redirected to another url and also i lost my rank in google search. after installing a plugin i think this problem is happened and after that i see unrelated result in google search console. i tried to delete viruses via worldfence and plugin found some viruses that i deleted them all but redirection is remained still there.
-
Please check your .htaccess file.– Pratik bhattCommented Jun 29, 2023 at 6:10
-
Clearly your website is hacked. Perform a thorough inspection in all your files and folders in WordPress installation, including the core files.– AbhikCommented Jun 29, 2023 at 7:25
-
If you're paying for premium Wordfence, let them know and have them clean it up. If you're not paying for premium, now is a good time to consider it. Hacks can be notoriously difficult to get rid of.– WebElaineCommented Jun 29, 2023 at 15:13
1 Answer
As mentioned in the comments, your site is probably hacked. I'd suspect the htaccess file first, and then maybe hacked index.php files.
Cleaning up a site is difficult and time-consuming, but can be done. Replace all WP core files, manually delete and reload (via FTP) plugins and themes, look for any unusual files (since you uploaded new files, check files for different date stamps).
Change the password on all accounts (hosting, FTP, database, admin-level account); strong passwords throughout. Look for extra 'admin' level user; demote them at the very least. All user accounts (especially admin-levels) should have passwords changed.
Manually inspect suspect files with hosting file manager. Look for 'funny' code. Check the posts database for unusual entries.
Then repeat inspections of files. Your SEO (search results) may take a couple of weeks to get back to normal, although you might be able to fast-track that by submitting new sitemaps. (Make sure your sitemaps files are valid.)
Monitor the site carefully for all of the above. Cleanup is hard, takes a long time, but can be done - I've done it for clients.