What is "rel = noopener noreferrer" link tag?
What is "rel = noopener noreferrer" link tag?
Student
I'm a professional writer and software developer with more than 10 years of experience. I have worked for a lot of businesses and can share sample works with you upon request. Chat me up and let's get started.....
The
rel="no opener no-referrer"attribute is a security and performance feature added to links in HTML. It is commonly used in conjunction with links that open in a new tab or window (i.e., links with thetarget="_blank"attribute). Here's a breakdown of what it does:1. "no opener"
noopenervalue prevents the new tab or window opened by the link from gaining access to the parent page via thewindow.openerproperty in JavaScript.noopener, the newly opened page can execute malicious scripts that manipulate or redirect the original page, creating a security vulnerability.2. "noreferrer"
noreferrervalue ensures that no referrer information (the URL of the original page) is sent to the new page.noopener, providing an additional layer of protection.Why Use
rel="noopener noreferrer"?window.opener.window.opener, it avoids unnecessary memory usage and performance hits caused by maintaining a connection between the two pages.