Skip to main content
All CollectionsTroubleshooting and FAQsFrequently Asked QuestionsGeneral
How to Remove the Suffix Number from the Page's/Post's URL
How to Remove the Suffix Number from the Page's/Post's URL

Prevent WordPress from add-on suffix number in the page's/post's URL.

Updated over 4 months ago

Permalinks in WordPress should always be unique. WordPress doesn't allow different Posts or Pages to have the same URL. Because of that, WordPress will insert a suffix number at the end of the actual Post/Page URL.

Example:

  • First Page URL: https://my-domain.com/my-page-name

  • Second Page URL: https://my-domain.com/my-page-name-2

If there are one or more Posts/Pages with the same slug WordPress will add a numbered suffix after the actual Post/Page URL.

That indicates that at least one Post or at least one Page uses the same slug.

Definition: A slug is part of the URL added after the domain name. WordPress automatically creates the slug based on the Post/Page title.

Remove the suffix number from the page's/post's URL

  1. Ensure that there is no other published post or page with the same slug

  2. Check the Trash Page and ensure no post or page uses the same slug

  3. Ensure that no image that is uploaded to the Media Library (WordPress →Media Library) uses the same name as the Post/Page's name that displays the suffix number

If any of the above is true, set unique names for those Pages/Posts.

Pro tip: Each image that is uploaded should be named to describe the page/area where it has been uploaded. To avoid creating suffix numbers, add the -img after the actual image name.

Example:

about-us.jpg used on the About Us page should be renamed to about-us-img.jpg

How to change the slug of an existing page/post

  1. From Dashboard → Pages load the page in question

  2. From the Right Sidebar, click on the URL of the page

    Edit the page slug name

  3. Manually change the slug

    Change the Page slug name

Repeat this process for all pages or posts that have the suffix number added.

How to change the name of an image from the Media Library

  1. Go to WordPress Dashboard → Media →Library

  2. Use the Search field to search for the image name

  3. Click on Edit

    Edit the image from Media Library

  4. Download the Image file to your local computer by clicking on the Download file link

    Download the image from Media Library

  5. Delete the image from your server

    Delete the image from Media Library

  6. Change the image name - ensure that the new image name is unique

  7. Upload the image back (with the new name)

  8. If the previous image was used in any of your layouts, replace it with the new image.

Did this answer your question?