Appearance
Manage Rank Math Archive SEO and Verification with AI
Use Easy MCP AI to let an AI client read and update Rank Math's webmaster verification codes and custom post-type archive titles and descriptions.
In this article
Before you start
- Activate Rank Math on your WordPress site.
- In WordPress, go to Easy MCP AI > Tools. Search for
wp_rm_get_settingsandwp_rm_update_settings, enable each tool, and click Save changes. - Make sure your AI connection allows both tools. The connected WordPress user needs the
rank_math_titlescapability; verification fields also requirerank_math_general. These capabilities control access to Rank Math's title and general settings.
Ask your AI client to call wp_rm_get_settings first. The response's settings contains the current values, and about explains the available fields. When calling wp_rm_update_settings, send only the top-level arguments you want to change; omitted settings keep their current values.
Webmaster verification
Webmaster verification proves to a service that you own your site. The supported fields are google_verify, bing_verify, baidu_verify, yandex_verify, pinterest_verify, and norton_verify. For each field, send the service's verification code or its matching <meta> tag. A tag for a different service is refused. Send an empty string to clear a saved code.
For example, pass {"google_verify":"YOUR_SERVICE_CODE"} to wp_rm_update_settings, replacing the placeholder with your Google verification code.
Rank Math prints these verification tags on the homepage only. Its Analytics module can temporarily print its own Search Console verification code instead of the value in google_verify.
Post-type archive titles and descriptions
A post-type archive is a page listing items of a content type, such as books. Use the types returned in settings.post_type_archives: Rank Math must expose the post type, and the type must have an archive.
Send post_type_archives to wp_rm_update_settings as a list of objects. Each object needs a post_type and at least one of title or description. For example, if book is returned, pass:
json
{"post_type_archives":[{"post_type":"book","title":"Books %sep% %sitename%"}]}Rows and fields you omit keep their current values, and Rank Math variables such as %sep% and %sitename% are preserved. An empty title or description restores Rank Math's fallback, %pt_plural% Archive %page% %sep% %sitename%, including for the description.
After an update, inspect the returned settings and changed_fields for the saved values and changes, and check stored_differently and not_saved for values saved differently or not saved. Clear the site's page cache before checking the public output; see Clear Site Caches with AI.