Skip to content

How can I have different robots.txt files for each store in a Magento installation with multiple stores?

I have a Magento installation with multiple stores, and I need to have different robots.txt files for each store. Currently, I have a single robots.txt file in the root directory of my Magento installation, but I want to customize it separately for each store.

Is there a specific configuration or code modification that needs to be done to have different robots.txt files for each store? I want to ensure that each store has its own set of rules and directives within the robots.txt file.

Any guidance or code examples would be greatly appreciated. Thank you!