search ]

Disable Yoast SEO Schema and Structured Data

Yoast automatically adds schema according to the settings you configured in the plugin. You can disable or remove this code using one of the following filters (depending on version).

For Yoast versions below 11.0, remove the schema with this filter:

function savvy_remove_yoast_json($data){
	$data = array();
	return $data;
}
add_filter('wpseo_json_ld_output', 'savvy_remove_yoast_json', 10, 1);

For Yoast versions 11.0 and above, use this filter:

add_filter( 'wpseo_json_ld_output', '__return_false' );
Join the Discussion
0 Comments  ]

Leave a Comment

To add code, use the buttons below. For instance, click the PHP button to insert PHP code within the shortcode. If you notice any typos, please let us know!

Savvy WordPress Development official logo