Answered a question that’s virtually identical to this very recently on the WordPress.org forums.
Custom Post Type Archive Page – Pagination Isn’t Working
I’ve provided a work-around / fix in that thread that should also work for you to.
🙂
EDIT: You also need to add the paging parameter to your query..
Eg.
$args = array(
'post_type' => 'my_post_type',
'paged' => get_query_var('paged') ? get_query_var('paged') : 1,
'posts_per_page' => 15,
);
$loop = new WP_Query;
$loop->query( $args );
I reformatted the code to make it a little more readable, end result will be the same.
Related Posts:
- Pagination not working with custom loop
- Have different number of posts on first page
- wp_pagenavi() with custom wp_query()?
- Custom Post Type Pagination Not Working On Archive Page
- Custom Post Type Archive Page: Set Posts Per Page, Paginate
- Archive page…limiting posts per page
- Pagination go to first page if i’m on last post
- Posts in Multiple Columns and Rows with one single loop
- Newer/Older posts links display same posts on every page
- Fix custom query pagination without changing site-wide posts-per-page settings
- posts_nav_link on single post template
- Pagination with custom post types results in 404 issues
- How i can add ‘N’ page of ‘N’ pages under posts loop?
- How can i change the output of posts_nav_link();
- How to display all posts from standard posts to custom post types in a loop with pagination?
- How To Show All Custom Post Types In A Category Instead Of Pagination?
- Custom Theme With Custom Loops
- Custom Post Types strange pagination problem
- pagination not working for category.php (custom post types in categories)
- Pagination Error : Duplicate argument being outputted
- Custom Post Type, Pagination and 404s?
- Custom post type pagination error
- Previous / Next Links For Custom Post Type Sorted By Meta_Value
- Custom archive page for custom taxonomy and pagination issue
- Custom post type paging return home page
- Pagination not working in custom post type. Help
- Pagination Not Working When Used With WP_Query() `offset` Property
- Why is my loop not populating the page with my custom taxonomy terms from my custom post type?
- next_posts_link() always generates second page link on custom post type
- Post navigation doesn’t show (in custom template, custom post type, custom query)
- 2 custom posts types, in their own columns, one pagination for both
- How to Fix Custom WordPress Loop with Pagination on Single Post View?
- Pagination on custom post types
- Pagination in custom post type page template
- Custom post type archive pagination with HTML5Blank theme?
- Pagination not working with custom loop
- Pagination not working with custom loop
- Pagination not working with custom loop
- Pagination not working with custom loop
- next_posts_link returns same content of 1st page
- Pagination not working with custom loop
- Fourth page of custom post type archive page does not exist
- Unable to display paging navigation with a custom post type loop
- WPNavi pagination links not working on custom pages
- Query Multiple Post Types and Paginate Newly Created List
- Woocommerce search pagination not working
- Custom template Page 2 not working
- A to Z List of Custom Post Type in three columns
- Custom post type, organized by categories
- What’s the WP way to load remaining custom posts?
- How do you paginate a query grouped by month?
- How to handle paged param in post and custom-post-type?
- WP Query with categories only shows one post and ignores the category
- What to and how to proceed with CPT to make DB small and efficient?
- List all posts in a custom post type with pagination (the correct way)
- Category with post type pagination returns 404
- Post ID randomly printing on page
- A custom post within a custom post
- custom post type pagination error 404
- Display Custom Taxonomy Alphabetically
- Full Custom Post Type List Organised by two Taxonomies
- Pagination issue on category.php using custom post type query
- Displaying Custom Posts on a Page
- Shortcode not working with post counter
- Problem: wp_query outputs all images on site
- Custom Post Type Pagination Paginates Only in URL Structure
- Get custom post type’s fields in a while loop as variables
- Is it possible to to use custom post type types on a page with the same slug somehow?
- WordPress custom post query with pagination
- Custom Post Type within the Loop on Homepage (Page Template)
- The loop seems stuck to a single (now deleted) post
- Posts per row on archive page (custom post type)
- How do I know the ‘meta_key’ for ordering my custom post type
- Next Post links not working in custom post type shortcode
- Querying Custom Post Type, ordering by Custom Taxonomy Pagination Not Working
- Pagination with custom query, custom search form, single and pages, ajax and no plugins
- Custom post type conditional in loop
- Listing all term items alphabetically / sorting loop
- can these 3 queries be re-written as 1 query?
- Losing Nav Active State in Menu
- Custom post type pagination – always return first page
- Display related custom taxonomy posts in sidebar
- Only show posts with date of today or in the future (i.e don’t show past posts)?
- How do I control the output of a custom post type in the loop?
- Display custom post type posts first, then default posts
- Custom Post Types in the WordPress Navigation Menu
- Custom Post Type Category Link
- Custom Post type category pages template and loop
- Three Most Recent Posts, One Per Term
- Targeting custom post type
- Does WP have a global of $id?
- WordPress Loop if/else
- Custom post type pagination 404
- get_the_title() is returning results from previous loop
- Custom Post Loop pulling all custom posts, not just one
- Conditional for a Single Post That Belongs to a Category?
- Wrapping x posts in html without leaving empty html
- WP Query post__in not returning correct results
- Custom Post Type single.php template only shows the latest post
- Sort posts in loop by the WooCommerce Membership of the author