SEO Basics

How Do I Insert Backlinks in a Website? (HTML and WordPress)

How Do I Insert Backlinks in a Website? (HTML and WordPress)

To insert a link on a page you control, wrap the anchor text in an HTML <a> tag, or in WordPress select the text, press Ctrl+K and paste the URL. A backlink to your site lives on someone else's page, so you cannot insert it yourself: you ask the owner, write a guest post, or trade an article.

The usual situation: a guide told you to "add backlinks to your site," you are in the page editor looking for the backlink button, and there isn't one. That is because the word covers two different things, and only one of them is something you can type.

Backlinks vs links: which one are you inserting?

A link you insert on your own site points somewhere else, or to another of your pages. A backlink is a link that points to your site from a page on another domain. You can add the first kind in seconds. The second kind exists only when another site owner publishes it, which is why it counts for anything: how backlinks work covers why Google treats them as votes.

So the question splits in two: how to insert a link on a page you control, and how to get a link inserted on a page you do not.

How to insert a link in HTML

The entire mechanism is one tag:

<a href="https://example.com/guide/">a guide to the topic</a>

Three details decide whether that link works for search engines. Google's guidance on crawlable links says Google "can only crawl your link if it's an <a> HTML element" with an href attribute, that the URL must resolve to "an actual web address," and that good anchor text "is descriptive, reasonably concise, and relevant to the page that it's on and to the page it links to." Buttons with onclick handlers, <span> elements and javascript: URLs may not be followed at all.

Add a rel attribute when the link is paid or user-submitted. Google's outbound link guidance, last updated on December 10, 2025, says to mark paid placements with rel="sponsored", comments and forum posts with rel="ugc", and to use rel="nofollow" "when other values don't apply." A normal editorial link needs no rel attribute at all. Dofollow vs nofollow links explains what each one does to ranking credit.

How to add a link in WordPress and other builders

Every editor does the same thing under the hood: it writes the <a> tag for you.

  • WordPress (block editor): highlight the text, click the link icon in the block toolbar or press Ctrl+K (Cmd+K on a Mac), paste the URL and press Enter. The link settings let you open it in a new tab or mark it nofollow.
  • Wix, Squarespace, Shopify, Webflow: highlight the text and use the link icon in the text toolbar. Each has a field for the URL and an option to open it in a new tab.
  • Classic editor or HTML mode: type the tag from the section above directly.

Whichever editor you use, check the result once in the published page's source: the link should be an <a href="..."> with the full URL, not a relative path that breaks on another domain.

How to get a backlink inserted on another website

You cannot log in to someone else's site, so a backlink always starts as a request. Three approaches work without breaking Google's rules:

  1. Ask for an insertion into an existing article. Find a live article that mentions your topic and leaves a gap, point to the exact paragraph, and explain in one sentence what your page adds. The full approach is in how to create backlinks.
  2. Write a guest post. You supply the article, the site publishes it with a contextual link to your page. See how to write a guest post that gets accepted.
  3. Trade articles with another site owner. Each of you publishes a piece that links to the other, in content. On Backlinkster, whoever starts a swap publishes the partner's article first, the link you submit must be a real article URL on your own domain rather than the homepage, and each swap is verified by API.

What you should not do is pay for an insertion that passes ranking credit. Google's spam policies list "exchanging money for links, or posts that contain links" as link spam unless the link carries rel="sponsored" or rel="nofollow", which removes the benefit you paid for. It is not cheap either: Ahrefs' outreach to 450 sites across nine niches found paid insertions averaging $361.44 each.

Where on the page a link should go

Inside the body text, in a sentence that would still make sense if the link were removed. Links in footers, sidebars and author boxes are treated as boilerplate and carry far less weight, which does link position on a page matter goes through. The same applies to backlinks you ask for: an in-content mention in a relevant paragraph is the placement worth requesting.

Anchor text should describe the destination. "Click here" tells a search engine nothing; "a guide to anchor text" tells it what the page is about. What is anchor text covers how much variety a natural profile has.

Mistakes that make an inserted link worthless

  • A link that is not an <a> tag. Buttons, onclick navigation and <span> elements with an href are listed by Google as not recommended. Do JavaScript links pass SEO value has the test cases.
  • An image link with no alt text. Google uses the image's alt attribute as the anchor text, so an empty one is an empty anchor.
  • The same exact-match anchor everywhere. A hundred links all reading "best accounting software" is a pattern, not a profile.
  • Linking the homepage when a deeper page fits. A backlink to the page that answers the reader's question helps that page rank; a homepage link spreads the credit thin.
  • Relative URLs in content syndicated elsewhere. /guide/ on another domain points at their site, not yours.

Frequently asked questions

Can I add backlinks to my own website? Not in the sense that counts. A link you add to your own page is an internal or outbound link. A backlink is a link to you from another domain, and only that domain's owner can publish it. You can make it easy for them to say yes, but you cannot insert it.

How do I insert a backlink in WordPress? If you mean a link inside your post, highlight the text, press Ctrl+K, paste the URL and press Enter. If you mean a backlink to your site, there is no WordPress setting for it: you need another site to link to you, through a guest post, a requested insertion or a swap.

What is the HTML code for a backlink? The same as any link: <a href="https://yoursite.com/page/">descriptive anchor text</a>. The difference is where it lives. On another site's page, that line is a backlink to you; on your own page, it is just a link.

Should I use nofollow on links I insert? Only when the link is paid, user-submitted or untrusted. Google asks for rel="sponsored" on paid links and rel="ugc" on comments and forum posts. An ordinary editorial link to a page you genuinely recommend should have no rel attribute, so it passes credit normally.

How do I add a backlink to an existing article on another site? Email the owner with the exact paragraph, the sentence you would add and the reason it improves their article. Keep the anchor natural and offer something fair in return, such as a relevant link from your own content. Paying for the insertion makes it a paid link under Google's rules.

Related: How to create backlinks: 7 methods · What is anchor text? · Dofollow vs nofollow links · Does link position on a page matter? · Do JavaScript links pass SEO value?

Keep reading

SEO BasicsLink Building vs Backlinks: What's the Difference?Read → SEO BasicsDo Newsletter and Substack Links Count as Backlinks?Read → SEO BasicsDo YouTube Description Links Count as Backlinks?Read →