Note: You are viewing the documentation for Version 3View Version 4 Docs


View the installation guide, browse the Knowledge Base, find out about SearchWP's many hooks, get support

Available since: 3.0


View Parameters »

Note: Use of this hook will require a manual reindex

By default SearchWP will parse blocks when a post has been created using the block editor (sometimes referred to as Gutenberg) but if you would like to prevent that from happening you can do so with this hook:

// Prevent SearchWP from parsing Gutenberg blocks during indexing.
add_filter( 'searchwp_do_blocks', '__return_false' );
view raw functions.php hosted with ❤ by GitHub


Parameter Type Description
$parse_blocks Boolean

Whether blocks are parsed before indexing

Fix keyword search on your site. No coding required!

Now you can utilize all of the content that's gone unrecognized by native WordPress keyword search instantly with SearchWP

Get SearchWP