I am having a problem when I try open url /author I always get 404.

For example if I open url

http://example.com/author/author-1 - OK
http://example.com/author/ - 404 why?

I try to create page-author.php and resave permalink, but get same result. Also in rewrite rules I see default values

    object(WP_Rewrite)#3250 (24) {
  string(36) "/%year%/%monthnum%/%day%/%postname%/"
  string(6) "author"
  string(6) "search"
  string(8) "comments"
  string(4) "page"
  string(12) "comment-page"
  string(4) "feed"
  string(1) "/"
  string(0) ""
  string(9) "index.php"
  string(0) ""
  array(0) {

What I can do to see my author page ( author page with list of author )?


Your example would be accurate if we were talking about a post type, but authors behave a little differently. WordPress automatically creates specific author pages (like your /author-1 example) but does not have a fallback scenario for showing a list of the authors. (More details on how the template hierarchy works can be found here)

So, you'll need to use a 3rd party plugin to generate an author list, or create your own. You ca create a page template and use the wp_list_authors() function (documentation) to generate a list of your authors (you can usually adapt your archive template to fit this use case fairly easily). Check out this Smashing Mag article for a more detailed walk through.

| improve this answer | |
  • This is standard author.php page, I don't have post type author. I createa author.php to show author posts and this template work good. But I don't know which template I need use to show all author in one page. I no need code, I only want to know why I can't use /author to show my custom page, like page-author.php If i create this page I always get 404 if try use it. – Brotheryura Jan 7 '18 at 19:29
  • Ok thx I find problem in part of rewrite rules, some plugin break it. When I removed all plugins and check in default theme it work fine. Thx! – Brotheryura Jan 7 '18 at 22:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.