Title: WordPress custom post type &#8211; permalink issue
Last modified: September 1, 2016

---

# WordPress custom post type – permalink issue

 *  [motard](https://wordpress.org/support/users/motard/)
 * (@motard)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-custom-post-type-permalink-issue/)
 * I am having the following problem. I have created a custom post type called services.
   When I create a new service, lets call it xpto, the permalink looks something
   like this `domain/services/xpto`. And I would like the permalink to be something
   like this `domain/xpto`.
 * My Settings->Permalinks are set to Post name domain/sample-post, and in the function
   I used to create the post in functions.php, I have tried several options in the
   rewrite argument, but to no success.
 * Help please.

Viewing 1 replies (of 1 total)

 *  [Nisha](https://wordpress.org/support/users/nishasingh/)
 * (@nishasingh)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-custom-post-type-permalink-issue/#post-7717346)
 * Hi,
 * You have to write the custom code.
    Check this [github code ](https://gist.github.com/kasparsd/2924900)

Viewing 1 replies (of 1 total)

The topic ‘WordPress custom post type – permalink issue’ is closed to new replies.

## Tags

 * [permalinks](https://wordpress.org/support/topic-tag/permalinks/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [Nisha](https://wordpress.org/support/users/nishasingh/)
 * Last activity: [9 years, 8 months ago](https://wordpress.org/support/topic/wordpress-custom-post-type-permalink-issue/#post-7717346)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
