What Is the Add Nofollow feature?
WordPress’s default behavior is to render links as written: <a href="https://example.com">text</a>. Add Nofollow intercepts this at the the_content filter and adds two attributes to all external links:
rel="nofollow": Tells search engines not to pass link equity to the linked pagetarget="_blank": Opens the link in a new browser tab (keeps the visitor on your site)
Internal links (links pointing to your own domain) are not modified. The feature does not change the link’s text, URL, or any other attributes you’ve manually set.
Why You Need It
- SEO:
rel="nofollow"tells search engines like Google not to pass PageRank to the linked site. This concentrates your link equity on your own content rather than spreading it to external sites - User experience:
target="_blank"opens external links in a new tab, so visitors don’t navigate away from your site. They can read the external content and still have your site open - Spam reduction: Spammers and low-quality linkers avoid sites that nofollow external links, because the backlink they get from your site has no SEO value
- Compliance: Some sites are required by policy or regulation to nofollow certain external links (e.g., sponsored content per Google guidelines)
The trade-off is that some legitimate sites may not link to you if you nofollow all externals (they want the link equity back). For most sites, the SEO and UX benefits outweigh this concern.
How to Use Add Nofollow in Classic Monks
Step 1: Navigate to Settings
Click into the Classic Monks plugin settings in your WordPress dashboard.
Step 2: Go to the Content Subtab
Click on the Core menu, then click the Content subtab.
Step 3: Enable Add Nofollow to External Links
Scroll to the SEO and Visibility section and toggle on Add nofollow to External Links and Open in New Tab.

Step 4: Save Changes
Click Save Changes.
Step 5: Verify
Open any post with external links on the front-end. View the page source. External links should have rel="nofollow" target="_blank" in their <a> tags. Internal links (to your own domain) should be unchanged.

Configuration Options
| Option | Description | Default |
|---|---|---|
| Add nofollow to External Links and Open in New Tab | Master toggle. Applies both attributes. | Off |
No nested options. The toggle is global.
What Gets Modified
| Link type | Before | After |
|---|---|---|
External link in post content (<a href="https://other-site.com">text</a>) |
No rel, no target | <a rel="nofollow" target="_blank" href="https://other-site.com">text</a> |
Internal link in post content (<a href="/about/">text</a>) |
Unchanged | Unchanged |
| External link in custom HTML blocks | No rel, no target | Modified (if processed by the_content filter) |
| Links in widgets | Depends on widget | Modified (if widget calls the_content filter) |
| Links in navigation menus | Unchanged | Unchanged (menus don’t go through the_content) |
| Links in comments | Unchanged | Unchanged (comments are filtered separately) |
How the Feature Decides “External”
The feature compares each link’s host to your site’s host (home_url()‘s host). If they match (including www vs non-www and subdomain handling), the link is internal. If they don’t match, the link is external and gets the attributes added.
Edge cases:
- Subdomain links: A link to
blog.yoursite.comis considered internal if your site is atyoursite.comAND the subdomain is configured. Otherwise, it’s external. - Protocol-relative links: A link starting with
//(e.g.,//cdn.example.com) is treated as external by default. - Anchor-only links: A link starting with
#is not modified (it’s a page anchor, not an external link). - Mailto and tel links: A
mailto:ortel:link is not modified (it’s not an external HTTP link). - Same-site cross-domain: A link to
yoursite.comfromwww.yoursite.comis considered internal if both resolve to the same site.
Developer Notes
This feature is a single toggle with no developer hooks currently exposed. The feature-specific logic is loaded conditionally when the toggle is enabled.
Options used:
| Option | Type | Default |
|---|---|---|
| Feature toggle | Boolean | false |