Overview
Insert Headers And Footers describes itself as: “Include inline javascript, stylesheets, CSS code or anything you want in Header and Footer areas of your WordPress with ease.”
It is active on 200,000+ WordPress sites and rated 5.0 out of 5 by 135 users on WordPress.org. Developers can extend it through 6 actions and 22 filters, listed below.
How to install Insert Headers And Footers
- Open the plugin installer. In your WordPress dashboard go to Plugins → Add New Plugin.
- Search for it. Type “Insert Headers And Footers” and pick the one by Adnan.
- Install and activate. Click Install Now, then Activate.
Install with a zip file or WP-CLI
Download the zip from the WordPress.org plugin page, then go to Plugins → Add New Plugin → Upload Plugin, choose the file and click Install Now. Or from the command line:
wp plugin install wp-headers-and-footers --activateRequirements: WordPress 5.0+ · PHP 7.0.0+ · tested up to WordPress 7.1.4
Hooks & customisation
Insert Headers And Footers 3.2.0 fires 6 actions and 22 filters. Use them from your child theme or a snippets plugin to change how it behaves without editing its files.
// Filter to add or exclude scripts to and from the frontend body.
apply_filters( 'wp_hnf_body_script', true );
// Filter to add or exclude scripts to and from the frontend footer.
apply_filters( 'wp_hnf_footer_script', true );
// Filter to add or exclude scripts to and from the frontend header.
apply_filters( 'wp_hnf_header_script', true );
// Filter allowed SDK opt-out setting keys for AJAX toggles.
apply_filters( 'wpb_sdk_allowed_opt_out_settings', $allowed, $this->slug );
// Filter allowed page slugs for post-opt-in redirect.
apply_filters( 'wpb_sdk_allowed_redirect_page_slugs', $allowed, $slug, $module );
// Filter telemetry API base URL for a product.
apply_filters( 'wpb_sdk_api_endpoint', $endpoint, $slug );Need Insert Headers And Footers customised?
Tell us what you want changed, added or fixed and we'll reply with an estimate.
WP EXPERTS is independent and not affiliated with Adnan. Plugin names and logos belong to their owners. Version, rating and install figures from WordPress.org, checked Nov 17, 2026.