16

I've got a pdf that I'd like to protect and don't want search engines to index it.

Currently, my link is as follows:

<a href="https://example.com/mypdf.pdf" target="_blank" rel="noopener">View PDF</a>

Would I be able to add nofollow tag to the rel tag?

Would I then divide these two with a coma or no coma?

Currently trying rel=nofollow noopener without coma.

Would I be able to add noindex to the same tag?

<a href="https://example.com/mypdf.pdf" target="_blank" rel="nofollow noindex noopener">View PDF</a>

Would this work?

Joe Bloggs
  • 1,410
  • 2
  • 24
  • 53
  • Yes you can, please read this alternate answer [here](https://webmasters.stackexchange.com/questions/111717/what-is-the-difference-between-nofollow-noopener-vs-just-nofollow) – Raul Reyes Oct 03 '18 at 03:50

1 Answers1

33

"nofollow" tag tells search engines "don't follow this link."

"noreferrer" tag indicates no referrer information to be leaked on this link.

"noopener" tag prevents the new page from being able to access the window.opener property (preventing malicious javascript).

you can use both something like this:

<a href="https://example.com/mypdf.pdf" target="_blank" rel="nofollow noopener">View PDF</a>

"noindex" you can't noindex a link. That would have to be defined on-page, in the meta data.

You're better off blocking pages in robots.txt if that's what you're after.

User-agent: * 
Disallow: /mypdf.pdf
Thiago Santos
  • 333
  • 3
  • 6
jameshenry10
  • 339
  • 2
  • 4
  • 2
    According to [MDN Doc](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel) `noreferrer` implies `noopener` but does `noopener` implies `nofollow`(or vice-versa)? I see no info about that but I would like a confirm if it's not implied in any of the both ways. – Xenos Dec 16 '19 at 16:53