Title: Changing Custom Post Type Structure&#8230;please help.
Last modified: September 1, 2016

---

# Changing Custom Post Type Structure…please help.

 *  Resolved [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/)
 * Hi…I kindda have a dilemma on changing to a new custom URL structure…im sure 
   this is quite common, but i’m hoping someone can help guide me through the steps
   to avoid any issues setting it up.
 * Currently, I have an existing custom post type called ‘apps’ – which looks something
   like this:
    - [http://www.sitename.com/apps/space-invaders](http://www.sitename.com/apps/space-invaders)
 * Instead, I would like to change ‘apps’ to ‘games’ — along with its console…for
   example:
    - [http://www.sitename.com/games/atari/space-invaders](http://www.sitename.com/games/atari/space-invaders)
 * I already have about 75 posts published with ‘apps’ as the custom post…so, im
   hoping I can easily make the change to the existing content without much hassle.
 * Any help and advice would be greatly appreciated.
 * Thanks!
 * [https://wordpress.org/plugins/custom-post-type-ui/](https://wordpress.org/plugins/custom-post-type-ui/)

Viewing 12 replies - 1 through 12 (of 12 total)

 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715676)
 * If you’re not wanting to mess with changing post_type values on 75 posts, you
   could try using the rewrite_slug field for the post type, and set that to “games”.
   It should make the urls use “games” instead.
 * Example:
 *     ```
       http://wds.dev/blog/games/test-appgame-mashup/
       ```
   
 * Image of admin:
    [https://cloudup.com/cBct22Eg0ak](https://cloudup.com/cBct22Eg0ak)
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715677)
 * Forgot to mention you’d potentially need to flush the rewrite rules, but that’s
   easy to do by visiting the permalinks page without changing any settings.
 *  Thread Starter [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715686)
 * Thanks for the quick reply….so, just to make sure I understand the process correctly
   for the existing 75 posts:
 * Within the Custom Post Type UI plugin:
    1. Go to the ‘Edit Post Type’ tab (created for ‘apps’).
    2. Scroll down to the ‘Custom Rewrite_slug’ field.
    3. Then, type in ‘games’
    4. SAVE
 * Then, go to the wordpress settings – ‘Permalinks’ and just re-save the page?
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715713)
 * Yeah, those steps look pretty accurate. Would be easy enough to undo as well,
   in case something is going wrong and need the urls back up asap.
 *  Thread Starter [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715722)
 * okay cool..I will test that out.
 * I just have a couple of more questions:
 * What about for adding the relationship to the URL structure…for example: after‘
   games’ i want to label the specific gaming console for that particular content.
    - [http://www.sitename.com/games/atari/pac-man](http://www.sitename.com/games/atari/pac-man)
    - [http://www.sitename.com/games/nintendo/super-mario-bros](http://www.sitename.com/games/nintendo/super-mario-bros)
 *  - /games —> atari/
    - /games —> nintendo/
 * Sorry, im not too familiar with the exact terminology to describe it. 🙂
 * I appreciate your help with this.
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715732)
 * Customizing the permalinks is the phrasing you’re looking for. That said, we 
   don’t have very much for that built into the plugin since it’s a topic that’s
   fairly complex, and also not available via the register_post_type() and register_taxonomy
   functions, which is what we focus on.
 * It’s definitely possible as a whole, for what it’s worth.
 *  Thread Starter [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715749)
 * I tested the ‘Custom Rewrite_slug’ and it worked to replace ‘apps’ to ‘games’…
   which is a good thing.
 * Also, regarding customizing the permalinks for custom post types…I found a plugin
   that seems to work fairly well & has some positive reviews…
    - [https://wordpress.org/plugins/custom-post-type-permalinks/](https://wordpress.org/plugins/custom-post-type-permalinks/)
 * I just have one other question regarding the ‘Custom Rewrite_slug’ vs. changing
   the post type slug…I noticed a checkbox that says ‘Migrate posts to newly renamed
   post type?’..hmm?
 * Would you say the custom rewrite_slug a better solution in this case, rather 
   than actually changing and migrating it?
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715750)
 * Both are viable options, depending on preference. I chose to suggest this route
   with the rewrite slug. While I’m confident the convert/rename method is solid
   and works, there is more to it under the hood, and thus *could* provide more 
   work. Also, any places that rely on post type slugs being used, need changed 
   in those cases. Changing the rewrite slug would not necessitate that. Both versions
   would require redirects, but only slug renaming requires code re-fiddling.
 *  Thread Starter [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715751)
 * oh okay, ya that make sense…so, as far as using the rewrite_slug, I assume then
   this option would be a solid long-term solution, right?
 * So, one quick last thing…after I do the rewrite_slug will I also need to do a‘
   redirect’ for my existing 75 posts that I published to avoid broken pages that
   were indexed by Google, correct?
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715754)
 * Yes, it’d be a long term solution. It’s not something unique to CPTUI, it’s been
   part of WordPress core for a long time.
 * Technically, yes, you would need to do a redirect, at least if WordPress doesn’t
   detect it and do its best to redirect for you. It does try its best to, but doesn’t
   always succeed. It’d be a pretty easy RedirectMatch as well, for what it’s worth.
 *  Thread Starter [WPDragon](https://wordpress.org/support/users/wpdragon/)
 * (@wpdragon)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715799)
 * oh okay, great. Thanks for all your help & quick replies.
 *  Plugin Contributor [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * (@tw2113)
 * The BenchPresser
 * [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715811)
 * Welcome.

Viewing 12 replies - 1 through 12 (of 12 total)

The topic ‘Changing Custom Post Type Structure…please help.’ is closed to new replies.

 * ![](https://ps.w.org/custom-post-type-ui/assets/icon-256x256.png?rev=2744389)
 * [Custom Post Type UI](https://wordpress.org/plugins/custom-post-type-ui/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/custom-post-type-ui/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/custom-post-type-ui/)
 * [Active Topics](https://wordpress.org/support/plugin/custom-post-type-ui/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/custom-post-type-ui/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/custom-post-type-ui/reviews/)

 * 12 replies
 * 2 participants
 * Last reply from: [Michael Beckwith](https://wordpress.org/support/users/tw2113/)
 * Last activity: [9 years, 8 months ago](https://wordpress.org/support/topic/changing-custom-post-type-structureplease-help/#post-7715811)
 * Status: resolved