apply_filters( 'rewrite_rules_array', string[] $this->rules )

Filters the full set of generated rewrite rules.

Parameters Parameters


(string[]) The compiled array of rewrite rules, keyed by their regex pattern.

Top ↑

Source Source

File: wp-includes/class-wp-rewrite.php

View on Trac

Top ↑

Changelog Changelog

Version Description
1.5.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

  1. Skip to note 1 content
    Contributed by Anthony Eden

    Here is a quick and dirty way you can list all Rewrite Rules registered on your site:

    add_filter('rewrite_rules_array', function($rules){
        return $rules;

    You could also drop this somewhere on your page:

    global $wp_rewrite;  

You must log in before being able to contribute a note or feedback.