can we make DAM pdfs not searchable from search engines? | Community
Skip to main content
This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

aanchal-sikka
Community Advisor
Community Advisor
December 7, 2023

@rookie80 

 

You would need to add following headers to pdf in Dispatcher

<LocationMatch "^/content/dam.*\.pdf.*">
Header set X-Robots-Tag "noindex, nofollow"
</LocationMatch>

 

Aanchal Sikka
rookie80Author
December 7, 2023

so where do I do this in AEM? can you please provide screenshots.

Thanks Mansi

aanchal-sikka
Community Advisor
Community Advisor
December 7, 2023

This configuration is done in Dispatcher. Please check for any existing config in code base via <LocationMatch keyword

 

It should be configured in following module:

<IfModule mod_headers.c>

 

 

Aanchal Sikka
Mahedi_Sabuj
Community Advisor
Community Advisor
December 7, 2023

HI @rookie80, You can prevent PDF from being indexed by search engines using robots.txt file.

Disallow: /*.pdf

 

 

Mahedi Sabuj
kautuk_sahni
Community Manager
Community Manager
December 11, 2023

@rookie80 Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.

Kautuk Sahni