Change Permalinks Structure to a Sequential Number for Each Post?

The ID of a post is not meant to be a sequence number in the sense that for post N the following post is N+1. The ID is an auto-incremented field in the posts table, which includes many things that are not published posts, e.g., drafts, pages, attachments. So there is really no way to force WordPress to assign sequential IDs in that field.

There are ways to produce a sequence number and then use it in the permalink structure, but any efficient system will involve storing the IDs in a separate location (table or option) and writing a custom rewrite plugin. That last bit is quite advanced.

It would be an intriguing problem for the experienced hacker to produce a plugin that solves this problem without significant performance degradation.

Leave a Comment