In short
Every link on a page tells Google two things: where another page is, and something about what that page is about. Most links need no rel attribute at all; you add rel="sponsored" to paid and affiliate links, rel="ugc" to links your users post, and rel="nofollow" when you do not want to vouch for the destination. All three are hints to Google, not commands, so use robots.txt or noindex when you really need to keep a URL out of crawling or out of the index.
What a link tells Google
Links do two jobs for Google. They are a discovery path: Googlebot finds new URLs by following them. And they are a signal: the link, its anchor text and the words around it help Google understand what the destination is about and how pages relate to each other.
A link on your page is made of four parts, and each one carries part of that message:
- The element: an
<a>tag. Without it, Google may not see a link at all. - The
href: the address. It has to resolve to a real URL Google can request. - The anchor text: the clickable words, or the
alttext of a linked image. - The
relattribute: an optional label that describes your relationship with the linked page: paid, user-generated, or not endorsed.
This lesson is about links inside your page content: links out to other sites, affiliate and sponsored links, links in comments and forums, and broken links in your text. How links tie your own site together is covered in the lesson "Internal linking and orphan pages". How links from other sites to yours are weighed is covered in "How Google evaluates links today".
What Google officially says
“Google uses links as a signal when determining the relevancy of pages and to find new pages to crawl.”
Google Search Central — Link best practices for Google“For regular links that you expect Google to fetch and parse without any qualifications, you don't need to add a rel attribute.”
Google Search Central — Qualify your outbound links to Google“Linking to other sites isn't something to be scared of; in fact, using external links can help establish trustworthiness (for example, citing your sources).”
Google Search Central — Link best practices for Google“Use nofollow only when you don't trust the source, and not for every external link on your site.”
Google Search Central — Link best practices for Google“If you were paid in some way for the link, qualify these links with sponsored or nofollow.”
Google Search Central — Link best practices for Google“Link spam is the practice of creating links to or from a site primarily for the purpose of manipulating search rankings.”
Google Search Central — Spam policies for Google web searchCrawlable link markup
Before any of the rest matters, Google has to recognise the link. The rule is short: “Generally, Google can only crawl your link if it's an <a> HTML element (also known as anchor element) with an href attribute.” And the flip side: “Most links in other formats won't be parsed and extracted by Google's crawlers.”
Google's own examples split cleanly:
- Recommended:
<a href="https://example.com">,<a href="/products/category/shoes">, and an<a href>that also has anonclickhandler or a class. - Not recommended:
<a routerLink="products/category">,<span href="https://example.com">,<a onclick="goto('https://example.com')">and<a href="javascript:goTo('products')">. Google may still try to parse these, but you should not rely on it.
JavaScript is fine as long as the result is a normal link: “Links are also crawlable when you use JavaScript to insert them into a page dynamically as long as it uses the HTML markup shown above.” The usual trouble is a <button> or a <div> with a click handler that changes the page. Users can navigate with it; Google cannot. For script-heavy sites, the rendering side is covered in the lesson "JavaScript SEO and rendering".
Anchor text: how to write it
“Anchor text (also known as link text) is the visible text of a link.” Google's documentation explains why it matters: “This text tells people and Google something about the page you're linking to.”
Google's standard for it is one sentence long: “Good anchor text is descriptive, reasonably concise, and relevant to the page that it's on and to the page it links to.” In practice that rules out three kinds of anchor:
- Too generic. “Click here”, “Read more”, “website” and “article” describe nothing. Google's suggested fix rewrites the sentence so the link reads “list of cheese types”.
- Too long. A whole sentence wrapped in a link is hard to scan. Link the words that name the destination and leave the rest as plain text.
- Stuffed. Google asks you to “Write as naturally as possible, and resist the urge to cram every keyword that's related to the page that you're linking to”. Keyword stuffing is a violation of its spam policies, and that includes anchors.
A useful test from the same page: “Try reading only the anchor text (out of context) and check if it's specific enough to make sense by itself.” Screen reader users often do exactly that, jumping from link to link, so a good anchor helps accessibility as well as search.
✓ Good
- See the
<a>list of cheese types</a> <a>ghost peppers</a>- Image link with
alt="add enchiladas to your cart" - Only the words that name the destination are linked
- Links spaced out, each with its own context in the sentence
✕ Bad
<a>Click here</a>to learn more<a>Read more</a>, or our<a>website</a>- Empty link, or image link with
alt="" - A whole sentence wrapped in one link
- Five links in a row, one word each
Three edge cases are worth knowing:
- Image links. “For images as links, Google uses the alt attribute of the img element as anchor text, so be sure to add descriptive alt text to your images”. A linked logo or product photo with
alt=""is a link with no anchor text. - Empty links. “As a fallback, Google can use the title attribute as anchor text if the <a> element is for some reason empty.” Treat this as a safety net, not a method; icon-only links should still have a text label or
aria-labelfor users. - Chained links. “Don't chain up links next to each other; it's harder for your readers to distinguish between links, and you lose surrounding text for each link.” The words before and after a link are part of its context.
If anchor text is inserted by JavaScript, Google's advice is to “use the URL Inspection Tool to make sure it's present in the rendered HTML.”
Outbound links: linking to other sites
Some site owners still avoid linking out, or add nofollow to every external link, in the belief that it "leaks" something. Google's documentation says the opposite: citing sources can help establish trust, and you should “Link out to external sites when it makes sense, and provide context to your readers about what they can expect.”
Good practice for outbound links:
- Link to the primary source. The study itself, the official documentation, the original announcement, not a page that summarises it.
- Use a plain link. A source you cite because it supports your point needs no
relvalue. - Describe the destination. The anchor and the sentence around it should tell readers what they will find, as with any other link.
- Do not count links. “There's no magical ideal number of links a given page should contain.” Google adds: “if you think it's too much, then it probably is.”
The case for nofollow on an outbound link is narrow. Google's example is a page that criticises another site: you want to link so readers can see what you are responding to, but you do not want to pass along your reputation. That is the moment for nofollow, not every link to a site you do not own.
The rel values: sponsored, ugc, nofollow
Google supports three values for qualifying an outbound link. Each one describes a different relationship, and the table puts Google's definitions side by side.
| Value | Google's definition | Use it for | Example |
|---|---|---|---|
sponsored | “Mark links that are advertisements or paid placements (commonly called paid links) with the sponsored value.” | Ads, sponsorships, affiliate links, sponsored posts, links in return for a free product | <a rel="sponsored" href="…"> |
ugc | “We recommend marking user-generated content (UGC) links, such as comments and forum posts, with the ugc value.” | Comments, forum and Q&A posts, user profiles, reviews written by users | <a rel="ugc" href="…"> |
nofollow | “Use the nofollow value when other values don't apply, and you'd rather Google not associate your site with, or crawl the linked page from, your site.” | A link you need to show but do not vouch for; also acceptable for paid links | <a rel="nofollow" href="…"> |
no rel | “For regular links that you expect Google to fetch and parse without any qualifications, you don't need to add a rel attribute.” | Editorial links: sources, recommendations, references, your own pages | <a href="…"> |
rel="sponsored"
Use it whenever the link exists because of a payment or other compensation: banner and text ads, sponsorships, affiliate links, paid reviews and guest posts, and links in content about a product you received for free. nofollow still works for these links: “The nofollow attribute was previously recommended for these types of links and is still an acceptable way to flag them, though sponsored is preferred.” You do not need to change old nofollow paid links; Google's 2019 announcement said “There's absolutely no need to change any nofollow links that you already have.”
rel="ugc"
Use it for links that your users, not your editors, put on the page: blog comments, forum threads, Q&A answers, profile pages, user reviews. Google also allows you to reward good members: “If you want to recognize and reward trustworthy contributors, you might remove this attribute from links posted by members or users who have consistently made high-quality contributions over time.”
rel="nofollow"
Use it when the link is neither paid nor user-generated but you still do not want to endorse it. Typical cases: a page you are criticising, a source you must cite but do not trust, a link in a press quote you reproduce. It is the fallback value, not the default for all outbound links.
Do not use it on links to your own pages to steer crawling or "save" ranking value. Google is explicit: “For links within your own site, use the robots.txt disallow rule.”
Combining rel values
One link can carry more than one value: “You may specify multiple rel values as a space- or comma-separated list.” Google's examples are rel="ugc nofollow" and rel="ugc,nofollow". The 2019 announcement answers the question directly: “Yes, you can use more than one rel value on a link.”
Useful combinations:
rel="ugc nofollow": a user-posted link, withnofollowkept for older systems that do not understandugc.rel="ugc sponsored": a user-posted link that is also paid, for example a forum post by a vendor promoting its product.rel="sponsored noopener": a paid link that opens in a new tab.noopeneris a browser value, not a search one; more on it below.
What if you pick the wrong value? Google's answer: “There's no wrong attribute except in the case of sponsored links.” Marking a comment link as sponsored costs little. Leaving a paid link unmarked is the real problem: “Any link that is clearly an ad or sponsored should use sponsored or nofollow, as described above.”
Wrong
<!-- affiliate link, no qualification -->
<a href="https://shop.example.com/?aff=123">
Buy the kettle</a>
<!-- comment link, no qualification -->
<a href="https://spam.example.net/">
cheap loans</a>
<!-- not a crawlable link -->
<span onclick="goto('/guide')">
Guide</span>
<!-- generic anchor -->
<a href="https://example.org/study">
click here</a>
- Paid and user links pass as editorial endorsements
- Google cannot extract the span as a link
- The anchor says nothing about the study
Right
<!-- affiliate link -->
<a href="https://shop.example.com/?aff=123"
rel="sponsored">Buy the kettle</a>
<!-- comment link -->
<a href="https://blog.example.net/"
rel="ugc nofollow">Anna's blog</a>
<!-- crawlable link -->
<a href="/guide">Kettle descaling guide</a>
<!-- descriptive anchor, new tab -->
<a href="https://example.org/study"
target="_blank" rel="noopener">
2026 limescale study</a>
- Each link states its relationship
- A real
<a href>Google can follow - The anchor names the destination
nofollow is a hint, not a block
Until 2019, Google did not count nofollow links at all. In September 2019 it introduced sponsored and ugc and changed the model: all three values are now “treated as hints about which links to consider or exclude within Search”. Google explained that links carry useful information, such as how the words in a link describe the page it points to, and that the hint model lets it keep that information. For crawling and indexing the change came a little later: “For crawling and indexing purposes, nofollow will become a hint as of March 1, 2020.”
Two consequences follow:
nofollowdoes not hide a page. “Links marked with these rel attributes will generally not be followed.” But Google adds: “Remember that the linked pages may be found through other means, such as sitemaps or links from other sites, and thus they may still be crawled.”- Use the right tool for your own URLs. “If you need to prevent Google from fetching a link to a page on your own site, use the robots.txt disallow rule.” And: “To prevent Google from indexing a page, allow crawling and use the noindex robots rule.”
Do not confuse the link attribute with the page-level rule. rel="nofollow" on an <a> tag applies to that one link. <meta name="robots" content="nofollow"> applies to every link on the page. The page-level version is covered in "Meta robots and X-Robots-Tag".
Affiliate and sponsored links
An affiliate link earns you a commission, so it is a paid link and gets rel="sponsored" (or nofollow). The same applies to sponsored posts, paid reviews, link inserts sold to advertisers and articles about products you received for free. Google's link spam examples include “Exchanging money for links, or posts that contain links”, “Exchanging goods or services for links” and “Sending someone a product in exchange for them writing about it and including a link”.
Paid links are not banned. Google's own words: “Google does understand that buying and selling links is a normal part of the economy of the web for advertising and sponsorship purposes.” The condition: “It's not a violation of our policies to have such links as long as they are qualified with a rel="nofollow" or rel="sponsored" attribute value to the <a> tag.”
In practice:
- Check the output, not the settings. Affiliate plugins, link cloakers and ad widgets often add
rel="sponsored", but not always. Open the rendered page and look at the actual<a>tags, including links behind redirect paths such as/go/kettle/. - Mark every paid link on the page, not only the first one or the button. Text links inside the review count too.
- Tell readers. A visible disclosure near the links is a legal requirement in many countries and simply honest. It is not a Google ranking rule, and
rel="sponsored"does not replace it.
Content matters as much as markup. Google's spam policies define thin affiliation as “the practice of publishing content with product affiliate links where the product descriptions and reviews are copied directly from the original merchant without any original content or added value.” They also say “Not every site that participates in an affiliate program is a thin affiliate.” Original reviews, real testing, comparisons and price information are what Google lists as added value. And its site reputation policy explicitly does not object to “Using affiliate links throughout a page, with links treated appropriately, or embedding third-party ad units throughout a page”.
User-generated links: comments, forums, profiles
Any place where visitors can post text with links will attract spam. Google's definition: “User-generated spam is spammy content added to a site by users through a channel intended for user content.” Its examples include spammy forum posts, comment spam on blogs and spammy accounts on hosting services. Google's link spam list also names “Forum comments with optimized links in the post or signature”.
A sound setup for any user-content area:
- Make
rel="ugc"the template default for links in comments, posts, signatures and profile fields. Addnofollowas well if other systems read your pages. - Moderate before publishing, or hold the first posts of new accounts for review. Use the anti-spam tools of your platform.
- Restrict links where they add nothing. Profile "website" fields and signatures are the favourite targets; consider removing links from them or showing links only to signed-in members.
- Reward trusted members. Removing
ugcfor long-standing, high-quality contributors is allowed, as Google's documentation says. - Clean up old threads. Spam that slipped through years ago still sits on your pages. Search old content for outbound links to unrelated topics.
Link spam on your own pages
Link spam is usually discussed as a backlink problem, but much of it lives in the HTML of the page that hosts the link. These patterns from Google's spam policy are things you control on your own site:
- Unqualified paid links. “Text advertisements or text links that don't block ranking credit”.
- Optimised anchors in sponsored content. Advertorials and guest posts with keyword-rich anchors that pass ranking credit.
- Template links. “Widely distributed links in the footers or templates of various sites”, such as a "Website by" credit with a keyword anchor on every client site.
- Hidden links. Google gives this example of hidden link abuse: “Hiding a link by only linking one small character (for example, a hyphen in the middle of a paragraph)”. White-on-white or off-screen links fall into the same category.
- Hacked links. Content injection can mean “adding hidden links or hidden text to a page by using CSS or HTML”. If your page links to casino or pharmacy sites you never added, treat it as a security incident.
The consequence is stated plainly in the spam policies: “Sites that violate our policies may rank lower in results or not appear in results at all.”
Broken links and redirects in content
Links rot. Pages move, sites close, domains expire. A broken link is a dead end for a reader and a sign that nobody maintains the page. Google does not publish a rule about broken outbound links, but keeping them working is basic page quality.
- 404 or dead domain. Find where the content moved and update the link. If it is gone, link to another good source, to an archived copy, or remove the link and adjust the sentence.
- Redirected link. Update the
hrefto the final URL. Each hop slows the user down, and long chains are fragile. - Expired domain taken over. A link to a respected blog can quietly turn into a link to a spam or gambling site after someone buys the expired domain. A link that still returns 200 is not necessarily still the page you cited, so spot-check old outbound links, not just status codes.
- Internal links in the text. Links to your own pages should point straight to the final URL that returns 200, never to a redirect or a 404. The details are in "Redirects and site migrations" and "Status codes, soft 404, 410".
A crawl of your site with outbound link checking turned on, repeated on a schedule, catches most of these. Prioritise pages that get traffic.
target="_blank" and rel="noopener"
Neither of these is a search signal. They are about security and user experience, and they often get mixed up with the SEO rel values because they live in the same attribute.
target="_blank"opens the link in a new tab. It has no effect on ranking or crawling.rel="noopener"stops the new page from controlling your page throughwindow.opener, which blocks an attack called reverse tabnabbing. Current browsers apply this behaviour by default totarget="_blank"links, so adding it is a harmless safeguard for older browsers.rel="noreferrer"also hides your page as the referrer. The destination's analytics will see the visit as direct traffic. That can be what you want for privacy, but it also hides your referrals from partners who track them.
Whether to open links in new tabs is a UX decision. Opening every link in a new tab breaks the back button for users. A sensible rule is to do it only when leaving the page would interrupt a task, such as a form or a checkout, and to signal it with an icon or text.
Check the links and status codes on your site
OurSEO Tools runs a 69-point checklist, including on-page, internal linking and redirects, and a technical crawl of up to 1,000 pages with the status code of every URL, so redirects and broken pages show up in one run.
Common mistakes
- ✕Plain affiliate linksPaid links without
sponsoredornofollow, often because a plugin setting was never checked. - ✕nofollow on every external linkGoogle says to use it only when you do not trust the source. Cited sources should be plain links.
- ✕nofollow on internal linksIt does not "save" ranking value. Use robots.txt to stop crawling and
noindexto stop indexing. - ✕Relying on nofollow to hide a pageIt is a hint, and the page can still be found through sitemaps or other links.
- ✕"Click here" and "read more" anchorsThey tell neither users nor Google what is on the other side.
- ✕Keyword-stuffed anchorsEspecially in guest posts and sponsored articles, where they look like link spam.
- ✕Image links with empty altA linked image without
alttext is a link without anchor text. - ✕Click handlers instead of linksA
<span>or<button>withonclickis not a link Google can follow. - ✕Unmoderated comment linksNo
ugcby default and no moderation turns a comment section into a spam outlet. - ✕Old links never rechecked404s, redirect chains and expired domains now serving spam.
FAQ
What is the difference between nofollow and sponsored?
sponsored says why the link is there: it is paid. nofollow only says you do not want to be associated with it. For paid links Google accepts both but prefers sponsored.
Do I have to replace my old nofollow paid links with sponsored?
No. Google said there is no need to change existing nofollow links. Use sponsored for new paid links when it is convenient.
Does linking to other sites hurt my rankings?
No. Google says external links can help establish trustworthiness, for example when you cite your sources. Link where it helps the reader, with a plain link.
Should comment links be ugc or nofollow?
ugc describes them best. rel="ugc nofollow" is also valid if you want older systems to understand it.
What happens if I leave a paid link unmarked?
Unqualified paid links are listed as link spam in Google's spam policies, and sites that violate those policies may rank lower or not appear in results at all. Marking the link with sponsored or nofollow removes the problem.
Does rel="noopener" or target="_blank" affect SEO?
No. noopener is a browser security setting and target="_blank" only opens a new tab. Neither changes how Google treats the link.
Sources
- Google Search Central — Link best practices for Google
- Google Search Central — Qualify your outbound links to Google
- Google Search Central — Spam policies for Google web search
- Google Search Central Blog — Evolving "nofollow": new ways to identify the nature of links (10 September 2019)
Quotes checked against the official pages on 30 October 2026.