WordPress – Permalinks

Permalinks is the permanent links/urls of the individual pages on your WordPress website.

People use these links to open your pages.

For example: the permalink of this post is https://aliceding.com/wordpress-permalinks/

The setting of permalinks is under “Settings -> Permalinks” (The url is https://yourdomain.com/wp-admin/options-permalink.php)

Please make sure your permainlink structure is ending with %post_id% or %postname%. In this way, each permalink goes to a unique page.

There are three basic types of permalinks.

1. Plain – This is the default one. It always work if you type in this plain one into browser.

http://yourdomain.com/?p=X

X is the Post ID number.

2. Pretty Permalinks: it is just as it says.  The URLs are built in a way that makes sense and comprehensible.

http://yourdomain.com/2021/post-title/

http://yourdomain.com/2021/12/21/post-title

http://yourdomain.com/archives/2021/12/21/post-title/

It is easily understand without any strange parameters such as “?p=X”.  What is p?  Not many people understand it.  However, using pretty permalink structures, you can easily get it.  For example, http://yourdomain.com/2021/12/21/post-title, it is posted on December 21, 2021.  The post title is “post-title”.

(Pretty Permalink is produced by mod_rewrite, lighttpd, or NGinx with try-files, etc.)

3. PATHINFO: “Almost Pretty”

http://yourdomain.com/index.php/yyyy/mm/dd/post-title/

PATHINFO permalinks are similar with mod_rewrite permalinks.  There is only one difference.  They have “index.php”.

(To activate PATHINFO permalinks, please start your custom permalink structure with index.php/)

 

Structure Tags

%year%

%monthnum%

%day%

%hour%

%minute%

%second%

%post_id%

%post_name%

%category%

%author%

 

(Visited 17 times, 1 visits today)