How Do I Change the URL for AJAX in WordPress?

Changing the URL for AJAX in WordPress is simple. Go to your WordPress admin area and select “Settings” from the menu. In the “Settings” area, select “General” and then under “Website Address” you will see the “AJAX URL.” Simply change the URL to the URL you want WordPress to use for AJAX calls. For example, if you want WordPress to use the URL http://www.example.

com/ajax/my_ajax.php, you would change the AJAX URL to http://www.com/ajax/my_ajax.php.