How is Membership 2 Pro info written at the DB

How are memberships created in the database?

Need to copy one membership (with its ID) to a fresh install.

Hope this makes sense.


  • Kasia Swiderska
    • Support nomad

    Hello Cultiva Tus Ideas,

    Data of membership is kept in two tables wp_postmeta and wp_posts (wp_ is prefix for database and it can be different for your site).

    In wp_postmeta name of membership is in meta_value and in wp_posts it is post_title

    it looks like that in PHPmyadmin

    Let me know if you have more questions

    kind regards,


  • Cultiva Tus Ideas
    • Site Builder, Child of Zeus

    Great, thats what i thought.

    What about wp_options? There are some Membership2 settings stored in this table.

    1. Is there any problem if i modify this manually?

    2. Is it ok if i modify ID at wp_posts and then post_id at wp_postmeta (about the same membership), to match a membership in a new site with the ID of an old site?

    We are importing many posts from an old site with a membership shortcode, especifically with membership id=”15315″. So, in the new site, we need to have this membership created with the same ID.


  • Patrick
    • Support Monkey

    Hi there Cultiva Tus Ideas

    Indeed, you should be able to modify the data in your database of the new site to match that of the old. The best way to test that is to actually test it, preferably on a sandbox or development site.

    Edit the info in the database of the new site, then test the process of registering on that subscription on your test site. If all goes as expected, and I see no reason it shouldn’t (but best to test first), go ahead and replicate on your “real” new site.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.