How to Configure WordPress Permalink Settings

The default WordPress permalink settings control the URL format for all posts, pages, categories, and tags

These settings apply globally, which means the same structure is used for all posts, one for all categories, and one for all tag archives.

For small or simple websites, this is usually enough, but it does not handle custom post types and taxonomies well. Their permalinks cannot be fully customized using only the built-in options.

If you need more flexibility, custom permalink plugins allow you to set individual URLs or create structures that WordPress does not support natively.

In WordPress, you can select your permalink structure in the admin under "Settings > Permalinks". While this page gives you several options under "Common Settings", these apply exclusively to the default "Post" type (blog posts).

The "Common Settings" section (where you choose the permalink mode) applies exclusively to the default "Post" type (blog posts). Custom post types, such as Products, Portfolio, or Events, use their own permalink formats and are not affected by those settings.

Changing permalink in admin dashboard

By default, WordPress uses "Plain" permalinks. These URLs rely on query strings and numeric IDs that do not provide much context to your visitors or search engines.

Using the default "Plain" mode for permalinks is generally not recommended.

Most WordPress users prefer "Post Name" because it keeps URLs descriptive and straightforward, making links easier for visitors to read and for search engines to understand.

Pretty permalinks

  • Plain
    This structure uses a query-based URL that includes the post ID. This format is hard to read for visitors and not suitable for SEO.
    Example: https://example.com/?p=123
  • Day and name
    This structure includes the full date and the post title. It can be useful for news or time-based content, but the URL can become long.
    Example: https://example.com/2026/01/02/sample-post/
  • Month and name
    This format shows the month and year, followed by the post title. It keeps some date context while staying shorter than the above format.
    Example: https://example.com/2026/01/sample-post/
  • Numeric
    This structure places a numeric ID in the URL instead of the post title. It offers no context to users or search engines and is rarely recommended.
    Example: https://example.com/archives/123
  • Post name
    This structure uses only the post slug. It is the most common option because it is short, readable, and easy to understand.
    Example: https://example.com/sample-post/
Read Before Saving
Choosing the right setting now prevents 'broken links' later. If your site is already live and has visitors, changing these settings will break your old links. Only change these if your site is new, or if you are prepared to set up 301 redirects.

WordPress permalink structure tags are placeholders enclosed in % signs. When a URL is generated, each tag is replaced with the corresponding value. These tags can be combined under "Settings -> Permalinks" to define the URL format for blog posts.

The most commonly used tags are:

Tag Description
%postname% The post slug, usually based on the post title.
%post_id% The post's numeric ID.
%category% The post category slug, including parent categories if present.
%year% , %monthnum% , %day% The publication year, month, and day.
%hour% , %minute% , %second% The publication hour, minute, and second.
%author% The post author's slug.

For example, the permalink structure /%year%/%monthnum%/%postname%/ produces a URL like:

https://example.com/2026/01/sample-post/

Do WordPress Permalink Settings Apply to Custom Post Types and Taxonomies?

Permalink structure tags configured under "Settings -> Permalinks" apply only to the default Post type. The built-in permalink settings panel provides options for managing the URL structure of posts and pages, but the structure tags themselves are not used for pages.

Custom post types and taxonomies generally cannot use these tags freely either. Some plugins extend WordPress’s permalink settings with additional options for their own content types and add their own permastructure tags.

For example, WooCommerce provides permalink options for products, product categories, and product tags. In most cases, however, the permalink formats for custom post types and taxonomies cannot be edited from the built-in permalink settings.

To change custom post type permalinks, you need a plugin that extends the default WordPress permalink settings.

A plugin such as Permalink Manager adds this functionality, allowing you to modify permalink structures freely and set custom permalinks for individual items.

Permalink settings for custom post types and taxonomies

URI Editor opend on "Edit post" page

WordPress does not provide a dedicated setting for trailing slashes in the admin dashboard. The "Settings -> Permalinks" page does not include a checkbox, dropdown, or other control for this setting, which makes it easy to miss.

Instead, trailing slashes are determined by the permalink structure in the "Custom Structure" field. When the structure ends with a slash, WordPress adds a trailing slash to site URLs. When it does not, the slash is removed.

Add trailing slash

This single character affects the URLs of all content on the site, so it is worth checking carefully. For a full explanation of how to add, remove, or enforce trailing slashes, see the full article on trailing slash settings.

WordPress Address vs. Site Address URL: What Each One Controls

When users change permalink settings, they often miss two related options in "Settings -> General". These fields are named WordPress Address (URL) and Site Address (URL).

The first one tells WordPress where its core files are located on your server. The second one, is the homepage URL your visitors see. WordPress also uses it as the base for your canonical URLs.

These two settings are also used by permalink-related functions, whenever WordPress needs to get permalink for any post or page on your site.

Most websites use the same URL for both setting fields, so there is usually nothing to configure. They should be different when WordPress is installed in a subdirectory, such as /wp/.

In that case, the WordPress Address (URL) should include that directory path (e.g. https://example.com/wp/ ), while the Site Address (URL) stays at the root domain (e.g. https://example.com/ ).

"WordPress Address URL" and "Site Address URL"

What Happens When Site URLs Are Overwritten in wp-config.php

If you set WP_HOME or WP_SITEURL constants directly in wp-config.php file, WordPress ignores whatever you enter in "Settings -> General".

This means that if you change the URLs there, the dashboard will show that the changes were saved. Nothing will actually change, though and WordPress does not show a warning, so this can be tricky for most users to figure out.

define( 'WP_SITEURL', 'https://example.com' );
define( 'WP_HOME', 'https://example.com' );
Tip
If your site URLs are not updating through "Settings -> General", please check your wp-config.php file first and check for hardcoded URL constants.

If they are set there, remove them and then update your address through "Settings > General" as usual.

Where Are Permalinks Stored in WordPress?

By default, WordPress does not store full URLs in the database. Instead, it generates links dynamically, allowing your site to rebuild permalinks automatically whenever the URL structure changes.

The permalink settings are kept in the wp_options table under "permalink_structure" row, while each slug is stored separately. WordPress separates slugs from the global permalink settings because slug is the part of the URL that identifies a post, page, or taxonomy item.

The "permalink_structure" row only defines the general format for URLs and the slugs are created from titles and appear at the end of the URL. For example, a post titled "WordPress Permalink" will use the slug "wordpress-permalink" unless you change it manually.

In WordPress, slugs are stored in different database tables depending on the content type:

  • For posts, pages, and custom post types, the slug is saved in the "post_name" column of the wp_posts table.
  • Categories, tags, and other taxonomy terms store their slugs in the "slug" column of the wp_terms table.

Troubleshooting & FAQ

If your site only works with the default plain permalink structure, it usually points to a server or configuration issue. Common causes include:

  1. Server configuration
    Pretty permalinks rely on the server’s rewrite rules.

    Apache:

    WordPress needs to write to the .htaccess file. If permissions are restricted, WordPress cannot update this file with the necessary rules. Ensure your .htaccess is writable (644 permissions). Even with correct permissions, a malformed or misconfigured .htaccess file can still cause issues.

    NGINX:

    Use recommended configuration files or ensure that a try_files directive is added with the ?$args part included. Otherwise, non-default permalinks may break when query strings are used.
  2. Missing mod_rewrite module
    On Apache, the mod_rewrite module handles URL rewrite rules that WordPress uses for pretty permalinks. Without it, only plain URLs work and "pretty permalinks" return 404 errors.
  3. Caching issues
    Old caches from plugins, CDNs, or browser can serve outdated URLs. Clearing caches often fixes the issue.
  4. Conflicts with plugins or custom structures
    Custom post types, taxonomies, can create overlapping URL formats. If the rewrite rules conflict, and two or more of them match the same URL structure, WordPress cannot determine which content item to display showing "404" error page instead.

If you change permalink settings after content is published, existing URLs may stop working. This can lead to 404 errors for visitors and search engines. To prevent this, you should configure permalinks early and avoid modifying them later. If changes are necessary, old URLs should be redirected to the new ones.

Yes. When you update permalink settings, WordPress applies the new structure to existing posts and pages. If previous URLs are already indexed by search engines or linked from external websites, you should use redirects to avoid broken links.

Last updated by Maciej Bis on: August 16, 2026.


Maciej BisFounder of Permalink Manager & WordPress Developer

The developer behind Permalink Manager, a plugin for managing permalinks, has been working with WordPress, creating custom plugins and themes, for more than a decade.

Go up