Advanced Query Loop


This plugin introduces a Query Loop block variation that will empower users to be able to do much more complicated queries with the Query Loop block, such number of posts to display and post meta


Please use the either the support forum or the official repository for any questions or to log issues.

Available Controls

Multiple post types

Select additional post types for your query!

Post Count

Set the number of items you want to display (up to 50).

Include Posts

Choose the posts you want to display manually.

Exclude current post

Remove the current post from the query.


Choose whether you want to start at the first or 100th!

Post Meta Query

Generate complicated post meta queries using an interface that allows you to create a query based on meta_key, meta_value and the compare options. Combine multiple queries and determine if they combine results (OR) or narrow them down (AND).

Date Query

Query items before a date, after a date or between two dates or choose to show the post from the last 1, 3, 6 and 12 months.

Post Order controls

Sort in ascending or descending order by:

  • Author
  • Date
  • Last Modified Date
  • Title
  • Meta Value
  • Meta Value Num
  • Random
  • Menu Order (props to @jvanja)
  • Name (props @philbee)
  • Post ID (props to @markhowellsmead)

Please note that this is a slight duplication of the existing sorting controls. They both work interchangeably but it just looks a bit odd in the UI


  • Select how many posts you want to display and the number to start at.
  • Create complicated queries for post types with registered post meta.x
  • Query posts before a date, after a date or between two dates.


26. Mai 2024 1 reply
One of the best free plugins out there and certainly my favorite. Hope this plugin will be around for many more years. Great Job!
7. Mai 2024 1 reply
I really needed a way to create a custom archive page for a knowledge base custom post type using the full site editor. This plugin gave me all of the advanced query parameters that I expected core’s query block to have. I also really appreciate how easy it is to move from a query block to the advanced block. It’s truly seamless. Great job, and thank you so much!
29. April 2024 1 reply
Awesome plugin which finally makes it possible to pick posts by hand. This is a feature i am missing in the default query block and here you have kind of search field where you pick your desired posts by hand. my last wish: would be great to have a drag and drop function in that field to change the order of the posts.
27. Feber 2024 1 reply
There is so much work to do in WordPress Handbook with blocks. However this plugin is marvelous and even it is a open book to learn how extend blocks in WordPress. THANKS
Lies alle 12 Rezensionen

Mitwirkende & Entwickler

„Advanced Query Loop“ ist Open-Source-Software. Folgende Menschen haben an diesem Plugin mitgewirkt:


„Advanced Query Loop“ wurde in 4 Sprachen übersetzt. Danke an die Übersetzerinnen und Übersetzer für ihre Mitwirkung.

Übersetze „Advanced Query Loop“ in deine Sprache.

Interessiert an der Entwicklung?

Durchstöbere den Code, sieh dir das SVN Repository an oder abonniere das Entwicklungsprotokoll per RSS.



  • Add dynamic date ranges to see posts from the last 1, 3, 6 and 12 months.
  • Insert a new instance by typing „AQL“ or „aql“ and pressing enter.
  • Adds sorting by Name (props @philbee).
  • Bug fixes.


  • Addresses some PHP fatal errors caused by type hinting.


  • Add Sorting by Included Posts IDs.
  • Add sorting by Comment Count.
  • Major restructure for processing the query params.
  • Add release-drafter workflow.


  • Fixes issue with Exclude Current Post not being correctly set on templates.


  • Fixes an issue with the Exclude Current Post toggle causing the block to crash in some circumstances


  • Adds a Include Posts tool to allow manual curation of content to display (@props jenniferfarhat)


  • Fixes issues in PHP 8 and the date query. (props @krokodok)


  • Fixes issue with empty search parameter causing incorrect template to load (props @StreetDog71)
  • Fixes issue with all post type not being loaded ( props @aaronware)


  • Fixes issue with multiple AQL instances having settings leaked to each other.


  • ACF custom fields now show in the auto-complete dropdown list for Post Meta Queries ( props to @jvanja )
  • Adds sort by Post ID ( props to @markhowellsmead )
  • Fixes a typo in the Order By label.
  • Fixes a bug where a second AQL instances was getting post meta query values from the first.


  • Due to a change in core, Post Count can no longer be overridden when the block is set to inherit the query.
  • Adds Exclude current post option. Props to @Pulsar-X
  • Bump Tested Up To for 6.4
  • Adds better instructions for creating extension plugins.


  • Adds EXISTS as a compare option for Post Meta Queries.


  • Moves all controls into a single panel titled „Advanced Query Settings“.
  • Exposes SlotFills and filters to allow extension of plugin to add any featured you want.
  • Minor PHP warning fixes.


  • Addresses translations from not loading. HUGE thank you to @himaartwp for opening the issue and to everyone that helped with the Japanese translation!
  • Fixes minor php warnings in the editor


  • Addresses an issue where noindex was being added incorrectly due to an empty parameter. Props to @pedjas for reporting.
  • Small fixes to address some PHP warnings.


  • Small fixes to address some PHP warnings.


  • Adds Menu Order to the sort by options. Props to @jvanja for the Pull Request *


  • Adds support for sorting by Meta Value, Meta Value Num, and Random.
  • Adds transform to convert existing Query Loop instances into Advanced Query Loop blocks.
  • Adds a release command.
  • Adds support for querying multiple post types.


  • Fixes missing controls when not inheriting the query. Props to @cvladan for opening the support thread.


  • Introduce Post Order controls to sort by Author, Date, Last Modified Date, or Title in ascending or descending order. Props to @asterix for the suggestion of adding Last Modified Date.
  • Enable Post Count and Post Order controls even when inheriting the query.


  • Allow manual input of post meta. Props to @svenl77 for opening the support thread.


  • PRO TIP: Include the PHP files when you release the plugin :/


  • Adds custom icon.
  • Under the hood restructuring of code.


  • Small fix for PHP 8. Props to @markus9312 for opening the support thread.


  • Fix various PHP notices. Props to @wildworks for opening the support thread.
  • Add some information to the readmes.


  • Small fix to no longer show an empty pattern after inserting the block.


  • Initial release with support for post count, offset, post meta, and date queries.