Print

Wordfence Plugin Error 403 Forbidden Ajax

If you are trying to run WP Staging and it’s immediately stopped before the cloning process can be started, it might be worth to check if you have the Wordfence security plugin installed on your website.

If Wordfence is blocking the ajax request you will get an error like this when you open the browser console with F12:

wordfence error 403 ajax

It gets worst. This blocking of the file admin-ajax.php can even happen on sites where Wordfence is disabled at all as long as it is activated on the main website. The reason is Wordfence scans through all files in an iterating way no matter if those ones belong to the site where Wordfence is installed or not.

If there is one instance of Wordfence running in the parent WordPress installation it affects all the wordpress sites that are located below of that particular website, e.g.

​Domain1: /home/sites/public_html/
Domain2: /home/sites/public_html/domain1
Domain3: /home/sites/public_html/domain2

To prevent the issue, Wordfence must be configured properly in the parent wordpress and should be reconfigured in the child wordpress installations as well.

​Long story short, set Wordfence firewall option to learning mode on the parent site will resolve the ajax error for all of your other websites:

wordfence error 403 ajax solution

In the sample above the Wordfence plugin which is installed in WordPress installation located in ​/home/sites/public_html/
must have the training mode activated.