Appearance
Manage Rank Math Redirects with AI
Use Easy MCP AI to let an AI client read and manage redirects in Rank Math. This integration works with Rank Math's Redirections module and does not require the separate Redirection plugin.
In this article
Enable access
- Activate Rank Math and enable Redirections under Rank Math > Dashboard > Modules.
- Make sure the WordPress user connected to your AI client has Rank Math's Redirections permission. Administrators have this permission by default.
- In WordPress, go to Easy MCP AI > Tools > Abilities, switch on Rank Math SEO, and click Save changes. This integration is off by default.
- Make sure the AI connection allows the tools you want to use.
Headless CMS Support is only needed for wp_rm_get_head; you do not need it to manage redirects.

Read and change redirects
Rank Math provides five redirect tools:
wp_rm_list_redirectssearches and pages through redirects.wp_rm_get_redirectreads one redirect.wp_rm_create_redirectcreates a redirect.wp_rm_update_redirectupdates an existing redirect. Fields you leave out of the request keep their current values.wp_rm_delete_redirectsmoves or permanently deletes redirects.
When creating a redirect, choose its source using sources, a published post_id, or a term_id. The redirect code defaults to 301; 301, 302, and 307 redirects require a target. Codes 410 and 451 must not include a target. The redirect's status defaults to active.
Rank Math refuses invalid sources, a source that points to the home page, a redirect to the same URL, or a source already used by an active redirect.
For example, ask your AI client: “Check for an existing redirect, then create a 301 from /old-page to /new-page.”
Trash, restore, or permanently delete
wp_rm_delete_redirects accepts redirect_ids with 1–100 redirect IDs. By default, it moves those redirects to Rank Math's trash. Restore a trashed redirect with wp_rm_update_redirect and status: "active". Rank Math empties its trash after 30 days.
To permanently delete redirects, use force: true. Use this only when you intend to delete them permanently. If any requested ID does not exist, Rank Math refuses the call before changing anything. Destructive-action approval applies when it is enabled.