This project is not covered by Drupal’s security advisory policy.
This module is used to set the target and rel attribute(optionally) for external links within the body field content.
Highlights of the module
- It supports updates through Drush as well as using configuration form.
- It works with multi-value body field.
- It gives provision to set the different values to target attribute other than just '_blank'. Allowed values are _blank|_self|_parent|_top.
- It also gives provision to set the rel attribute with following allowed values along with the target attribute:
- nofollow
- noreferrer
- noopener
- external
- Update the nodes using batch processing.
- Set target and rel attribute inside the body field HTML instead of using Jquery.
How it works
This module has support with Drush and also provides an admin backend configuration form to run this update. We provided backend configuration by considering that, some times team will not have command-line access on the server to run the Drush command in that case they can use this backend configuration to run this update. Please follow README.md for the usage details.
When to use this module?
- Many sites have a requirement to open the external website links in new windows, tab or attach a rel attribute to such external URLs for better SEO tracking. In such a scenario, this module can be useful
- While working in de-coupled architecture, whenever there is a need to update all the external URLs with target and rel attributes, this module can be used.
- During the migration of content from a legacy system or any external system into Drupal, that time also we can use this module to set target and rel attributes after migration
Note: If the text format filter to 'limit allowed HTML tags and correct faulty HTML is enabled', then anchor links will not be updated.
Multi-lingual support will be released very soon!
Link Target Attribute Options

Link Rel Attribute Options

Project information
- Project categories: Content editing experience
- Created by vb_swapnil on , updated
This project is not covered by the security advisory policy.
Use at your own risk! It may have publicly disclosed vulnerabilities.



