Quick and Dirty migration from Add Meta Tags to Yoast SEO

joost-footerWordPress has many useful features, one being SEO management. If you’ve ever setup a WordPress site and installed the Add Meta Tags plugin and wish to migrate to Yoast SEO (or to anything for that matter), this step by step will help you keep all your data.

  1. Login to your wp_admin
  2. Install the Yoast SEO plugin (do not activate yet)
  3. Install MySQL Workbench or another MySQL admin tool.
  4. Login to your database
  5. If you are using MySQL Workbench, run a Data Export on the wp_postmeta table just in case something goes wrong.
  6. In the query console type then click the execute button:

    SELECT DISTINCT meta_key FROM <dbname>.wp_postmeta
    WHERE meta_key like ‘_amt_%’
    ORDER BY post_id DESC;

  7. You will now have a list of all the tags you use with “Add Meta Tags” plugin. Write these down.
  8. Clear the query console and type then click the execute button:

    Update <dbname>.wp_postmeta
    SET meta_key = ‘_yoast_wpseo_title’
    WHERE meta_key = ‘_amt_title’;Update <dbname>.wp_postmeta
    SET meta_key = ‘_yoast_wpseo_metadesc’
    WHERE meta_key = ‘_amt_description’;

    Update <dbname>.wp_postmeta
    SET meta_key = ‘_yoast_wpseo_metakeywords’
    WHERE meta_key = ‘_amt_keywords’;

  9. All your fields have now been migrated.
  10. Go back to your wp_admin and deactivate “Add Meta Tags”
  11. Activate Yoast SEO
  12. Enjoy the new SEO administration.

*Tip: If you are wanting the keywords field to add your own keywords.

  1. From the SEO menu on the left, click Titles & Metas
  2. Click the Other tab
  3. Check the box next to Use meta keyword tag

Other resources: http://www.drewslair.com/2015/01/converting-meta-descriptions-yoast-seo/