Sub topic 2
Anchor text, nofollow, sponsored and ugc attributes
This chapter assumes you know what a backlink is, can read an HTML anchor tag, and have seen a backlink export as a CSV file. It covers the two parts of a link that decide how much a link is worth: the anchor text and the rel attribute.
The parts of a link
A link in HTML has a destination and a visible label. It can also carry a rel attribute that tells search engines how to treat it.
<a href="https://example.com/event-tracking-guide" rel="nofollow">Guide to Event Tracking</a>hrefis the destination URL.- The text between the tags is the anchor text.
reldescribes the relationship between the two pages.
Anchor text
Anchor text is the clickable words of a link. Search engines read it as a hint about what the destination page covers. Anchor text falls into a few common types:
| Type | Example | Typical use |
|---|---|---|
| Branded | Acme Analytics | Mention reclamation |
| Naked URL | https://example.com/guide | Citations and lists |
| Descriptive | guide to event tracking | Broken link replacement |
| Exact match | web analytics software | Easy to over-use |
| Generic | click here | Low information |
In both tactics in this tutorial, you rarely choose the anchor text yourself. The site owner does. In broken link building, the existing anchor text stays and only the href changes. In mention reclamation, the brand name is already on the page, so the anchor will be branded. Branded and descriptive anchors look natural. A profile made mostly of exact-match anchors can look manipulated, which is covered in the ethics chapter.
The rel attribute values
Google recognizes three values that describe a link's relationship. You can combine them with spaces.
| Value | Meaning | Where you see it |
|---|---|---|
| `nofollow` | The publisher does not vouch for this link | Sites that link out cautiously |
| `sponsored` | The link was paid for or part of an ad or sponsorship | Ads, paid placements |
| `ugc` | The link sits in user-generated content | Comments, forum posts |
Google treats these values as hints. It may still use such links to discover pages or as a ranking signal. A link without any of them is usually called a followed link.
Why this matters for your two tactics
Both tactics aim for editorial links, which are links a site owner places by choice in the page body. These are normally followed. Attributes tell you what you are looking at when you review a prospect:
- A resource page with followed outbound links is a good broken link target.
- A mention inside a comment is probably
ugc, so a link there is a weak result. - A mention in a "sponsored post" is paid content, and asking for a followed link would be asking the publisher to break guidelines.
Checking attributes with code
When you verify a link, read its rel value instead of guessing.
from bs4 import BeautifulSoup
html = '<a href="https://acme-analytics.com" rel="nofollow ugc">Acme Analytics</a>'
soup = BeautifulSoup(html, "html.parser")
for a in soup.find_all("a", href=True):
rel = a.get("rel", [])
followed = not {"nofollow", "sponsored", "ugc"} & set(rel)
print(a.get_text(), rel, "followed" if followed else "not followed")BeautifulSoup returns rel as a list, which is why the code uses a set intersection. The pattern is a.get("rel", []) because the attribute may be missing. This prints Acme Analytics ['nofollow', 'ugc'] not followed.
Exercise
A page names your brand in a blog comment, and the commenter's link to your site has rel="ugc". Is this a good reclamation prospect, and why?
Show answer
It is a weak prospect. The link already exists, so the mention is not unlinked, and the ugc value tells search engines it came from user-generated content. A better target is an editorial mention in the article body that has no link at all.
Exercise
In broken link building, which part of the existing link do you ask the owner to change, and which part usually stays the same?
Show answer
You ask for the href to change from the dead URL to your replacement page. The anchor text usually stays the same, which keeps the link natural.