Add this to your code, before query_posts line:
$paged = get_query_var( 'paged' )?get_query_var( 'paged' ):1;
Should work.
Related Posts:
- Custom post type pagination 404 fix?
- How do I Paginate Search Results for Custom Post Types?
- Pagination throws 404 error on custom taxonomy archive pages
- Custom Post Type Archive Page: Set Posts Per Page, Paginate
- Archive page…limiting posts per page
- Shortcode Displaying Custom Post Types
- Related posts by author pagination not working on the production site
- Secondary loop pagination on custom post type single post gets redirected to first page
- Pagination go to first page if i’m on last post
- Pagination throws 404
- Custom Post Type pagination when CPT ‘rewrite’ rule and a page have the same slug
- paginate function in archive for custom-post-type
- custom post type paging not working past page 3
- Custom Post Type, Two categories, Two columns with Pagination
- Pagination gives 404 error
- Creating a simple pagination for custom post type templates
- Pagination not working
- Pagination Custom post type
- WordPress rewrite my URL when i use pagination
- Custom Post Type Pagination & duplicate posts
- Unable to get paginate_links working with a custom query [duplicate]
- Custom post type, permalinks & pagination, going wrong
- Repeating posts when paginating random posts
- Hard code the nextpage tag into my theme?
- Pagination for custom php code
- Pagination for Custom Taxonomy Page [duplicate]
- Pagination on with query_posts in custom post type template
- Pagination of Custom Post Types not Changing Posts
- Paging doesn’t work?
- Help with Elementor Pagination CPT archive 404 problem
- Custom taxonomy rewrite give pagination 404
- Next and Previous Posts of Same Parent
- How to handle paged param in post and custom-post-type?
- Category with post type pagination returns 404
- Pagination issue on category.php using custom post type query
- Next Post links not working in custom post type shortcode
- Custom Theme With Custom Loops
- Custom Post Types strange pagination problem
- Custom post type pagination – always return first page
- Cant get paginations on single.php to work with my custom post types
- Pagination custom post type not working with rewrite slug
- Pagination Not Working for Custom Taxonomy with Custom Query – 404 Error
- Custom WP_Query always respond with 200 status even when no entry
- Can’t use pagination with custom taxonomy
- Pagination 404 on Index with custom query
- Custom ordering of CPT items not matching with the ordering of its pagination
- Pagination doesnt work in custom post type
- Break up posts per page in two sections
- Pagination on search results page
- 404 Page Not Found on /Page/2/ on Tag Page
- How to list custom post types on a custom post type page?
- Custom Post Type Archive Pagination
- Taxonomy rewrite pagination 404
- Custom Post Type Pagination on Single.php?
- Custom post type pagination error
- Pagenavi Plugin and Custom Post Type – Multipage results
- Add pagination to custom single post template
- get_query_var(‘paged’) return 0 in custom category page
- Custom post type paging return home page
- Pagination on custom post type without plugin
- Remove custom taxonamy slug with pagination
- Add Pagination in custom Blog page template
- Custom post type, next and previous links by page title
- Why is my loop not populating the page with my custom taxonomy terms from my custom post type?
- Pagination for custom query returns 404
- Custom post type pagination problem – page 1 and 2 show same content
- Custom Post Type Pagination – not displaying posts
- How to add pagination to a post loop in a custom BuddyPress tab
- 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
- Pagination functions won’t work
- pagination for a custom query
- Paging not working for hierarchical custom post type
- Custom taxonomy in custom post type archive with pagination
- How to Fix Custom WordPress Loop with Pagination on Single Post View?
- why custom post archive gives always no more than 10 posts despite of paging settings?
- Pagination on custom post types
- How to display data with pagaination on backend?
- Custom Post Type Pagination Not Working or Single Posts Displaying?
- 404 error Custom search results page for custom post types with friendly URL
- Pagination in custom loop for custom post type throwing 404 error
- previous_posts_link returns null when querying custom post type
- Custom Post Type Pagination for Bones Theme [duplicate]
- Pagination for a Custom Taxonomy
- Pagination with Custom Post Type
- Pagination URL order
- WordPress Load more posts by ajax not working
- Paged within a custom content type template [duplicate]
- Pagination for event query
- WordPress custom post type post and category links 404
- Pagination not working for archive
- Archive page – problem with pagination
- See the process of creating a taxonomy and tell me where I made a mistake
- Pagination not working in custom post type
- Pagination not working
- Pagination on category pages using wp_pagenavi causes 404 errors
- CPT Archive Pagination – Page not found
- Custom post type pagination conflict result in 404
- Custom post type pagination not working in index.php file