Trusted WordPress tutorials, when you need them most.
Beginner’s Guide to WordPress
25 Million+
Websites using our plugins
Years of WordPress experience
WordPress tutorials
by experts


編集メモ: WPBeginner のパートナーリンクから手数料を得ています。手数料は編集者の意見や評価に影響を与えません。編集プロセスについて詳しく知る。




Migrate Custom Post Types





Getting the post type key

投稿キーを取得したら、投稿タイプをインポートしたいサイトにアクセスし、Custom Post Types UIプラグインを使ってカスタム投稿タイプを作成します。

Creating post type in CPT UI


Getting taxonomy key in WordPress

CPT UIプラグインを使用して、タクソノミーをインポートしたいターゲットサイトに同じタクソノミーを作成します。

Create Taxonomy in CPT UI plugin


ボーナスヒント:CPT UIプラグインを使って投稿タイプを作成した場合、それを使って移行することもできます。しかし、これは元のカスタム投稿タイプがこのプラグインを使って作成された場合にのみ機能します。プラグイン設定のインポート/エクスポートセクションにアクセスし、画面の指示に従ってください。






WordPressには強力なインポート/エクスポートツールがあり、WordPressのデータをエクスポート/インポートすることができます。ツール ” エクスポート.

Exporting custom post type in an XML file using WordPress built in export tool



次に、このデータをインポートしたいターゲットサイトに切り替えます。ツール ” インポート に進みます。いくつかのオプションが表示されますので、WordPressをクリックしてください。

WordPress import tool


Installing WordPress importer plugin


Importing WordPress using XML export file



この投稿を気に入っていただけたなら、WordPressの動画チュートリアルをYouTubeチャンネルに登録してください。Twitterや Facebookでもご覧いただけます。

情報開示 私たちのコンテンツは読者支援型です。これは、あなたが私たちのリンクの一部をクリックした場合、私たちはコミッションを得ることができることを意味します。 WPBeginnerの資金源 をご覧ください。3$編集プロセスをご覧ください。


Editorial Staff at WPBeginner is a team of WordPress experts led by Syed Balkhi with over 16 years of experience in WordPress, Web Hosting, eCommerce, SEO, and Marketing. Started in 2009, WPBeginner is now the largest free WordPress resource site in the industry and is often referred to as the Wikipedia for WordPress.


ツールキットへの無料アクセス - すべてのプロフェッショナルが持つべきWordPress関連製品とリソースのコレクション!

Reader Interactions


  1. Syed Balkhi says

    Hey WPBeginner readers,
    Did you know you can win exciting prizes by commenting on WPBeginner?
    Every month, our top blog commenters will win HUGE rewards, including premium WordPress plugin licenses and cash prizes.
    You can get more details about the contest from here.
    Start sharing your thoughts below to stand a chance to win!

  2. Kerry says

    I am trying to export CPT data, but the WP export tool doesn’t list the CPT. I’m using the CPT UI plugin. Any help?

    • WPBeginner Support says

      For that specific plugin, you would want to check under CPT UI, Tools and you should see that plugin’s specific method for importing and exporting post types.


  3. Bulut says

    There are people, Trouble Maker
    There are Bloggers, Trouble Eraser

    Thanks guys. You saved my day and time!

  4. Gabriela says


    We are switching themes – we want a new site basically – hopefully with a cleaner backend. The switch is from a custom-built theme to a new theme.
    Would it be best to install a new theme within our same back end, or would it be cleaner to export and import into a new backend?

  5. Raf says

    Clear incoherence between title and intent and practical advises:
    1) says “Exporting Custom Post Types and Taxonomies in WordPress”
    2) says “in some cases you may not be able to locate the code.”
    3) says “Don’t worry you can still create the same custom post type on the new site.”

    So if the post-type is created using the UI : you can not export it but only create it again. Why the article doesn’t clearly state it?

  6. Francis says

    So let say for instance if I was using a paid plugin that has to do with custom posts and want to switch to the free version how will i go about it? Am still very new to wordpress

  7. David says

    How can you export and have the option of exporting by month like you have when you export post and page?

  8. charles says

    When exporting custom post types it doesn’t export the featured image url path. Any idea how to resolve this?

    • Paul says

      I’m trying to do this too, which is why I landed here. I’m trying to rename a custom post type without losing the post data. Not having much luck.

    • Carlitos says

      It does not. you will want to bring that over either in your functions file or enter it in manually if you are using a plugin.

  9. Jim D says

    Is this something you would need to do if you are using a custom post type currently and wish to switch to a different theme?

    • WPBeginner Support says

      It depends on how you created the custom post types in the first place. If these custom post types were created by your old theme then you will need to export them before switching theme. If the custom post types were created using a plugin then they would remain unaffected when you switch the theme. Lastly, if you created the custom post type by adding code into your theme’s functions file then you just need to copy that code and paste it in your new theme.


  10. Philip Downer says

    This article should have a bit of clarification. As Kris touched on, you can only import a custom post type if that specific custom post type actually exists on the destination site. You’ll need to either export and include the code that registers the post type; or if you’re using a plugin to handle custom post types, you’ll need to ensure that the same settings are used.

  11. Kris says

    Not to forget: themes also make their own custom post types (portfolio for example). Not only moving a site, but also switching themes can also be difficult

    I ended up coding the post type and taxonomies in a separate site-specific plugin with the aid of; I was surprised how easy it went and found it less confusing then CPT-UI