# Unregistering Dynamic Tags

Elementor Core Intermediate

Developers can remove dynamic tags from the list of registered dynamic tags. This is done by hooking to the dynamic tags manager and unregistering specific dynamic tags by passing dynamic tag name.

# Unregistering Existing Dynamic Tags

As of Elementor 3.5, developers should use the following code to unregister existing dynamic tags:

/**
 * Unregister Elementor dynamic tags.
 *
 * @param \Elementor\Core\DynamicTags\Manager $dynamic_tags_manager Elementor dynamic tags manager.
 * @return void
 */
function register_dynamic_tags( $dynamic_tags_manager ) {

	$dynamic_tags_manager->unregister( 'dynamic-tag-1' );
	$dynamic_tags_manager->unregister( 'dynamic-tag-2' );

}
add_action( 'elementor/dynamic_tags/register', 'register_dynamic_tags' );
1
2
3
4
5
6
7
8
9
10
11
12
13

This hooks to the elementor/dynamic_tags/register action hook which holds the dynamic tags manager. The manager then unregisters the dynamic tag by passing the dynamic tag name.