How to add Referrer Policy Meta Tag on a WordPress Site

This document outlines the steps to add a Referrer Policy Meta Tag to a WordPress based site that restores the ‘Referrer Policy’ to “no-referrer-when downgrade” from the recently forced change by Google of “strict-origin-when-cross-origin”.  For further information about this global change by Google please read this article.

Otherwise, after logging in to wp-admin portion of your site you should be able to do one of the following to resolve the issue.

** Warning – if you modify the Theme, be certain you have configured your WordPress site so that updates to your Theme will not remove your change (i.e. using a Child Theme). **

Modifying the Theme Directly:

  1. From your dashboard, open your Theme Editor

2. Next find the Theme Header object (most if not all WP Themes have a Theme Header). Should be in the column on the far right with “Theme Files” at the top.

3. Once you have your Theme Header file selected it should open the code in the larger window, just to the left of the “Theme Files” column. Near the top of that code you should see some common HTML (like the following). Just add the necessary tag between the <head> and </head> tags. The line you want to add is:  <meta name=”referrer” content=”no-referrer-when-downgrade” />

If using this method, you are done. Just click the “Update File” button below the code window so the code is updated on your site. If your site uses caching of any sort, you may want to clear it so the updated change will get pushed immediately.

If using a plugin to manage the change

There are many plugins that offer the ability to add items to the header and footer of a WordPress site. I will demonstrate just one of these, though the concept should be similar across the board. I have chosen to demonstrate how to do this using the “Insert Headers and Footers” plugin.

**NOTE: This documentation assumes you have installed the plugin and that it is active.**

  1. From the dashboard, get to the Settings for the Header/Footer plugin you have chosen. Generally it will be like the following, but may have it’s own interface.

2. Once you are in the plugin’s interface, there should be away to add to the “Header”. Locate that and add the necessary meta tag to that input area. What you want to add is:
<meta name=”referrer” content=”no-referrer-when-downgrade” />

That’s it, just save the changes. If your site is hosted with some sort of caching you may wish to flush the cache so that the change takes affect immediately.