- HTML Links
- HTML Links — Hyperlinks
- HTML Links — Syntax
- Example
- HTML Links — The target Attribute
- Example
- Absolute URLs vs. Relative URLs
- Example
- Absolute URLs
- Relative URLs
- HTML Links — Use an Image as a Link
- Example
- Link to an Email Address
- Example
- Button as a Link
- Example
- Link Titles
- Mastering the Art of Embedding Links with the and Tags in HTML
- Understanding the tag and the href attribute
- Using anchor links to navigate within a page
- Learn HTML link tag in just 6 minutes. How to insert links in HTML
- Creating embedded links with anchor text
- Bonus tips for creating and optimizing links
- How to Make a Hyperlink (Create Clickable Links in 3 Easy Steps)
- What Is a Hyperlink?
- How To Make a Hyperlink
- How Do I Make a Clickable Link in WordPress?
- How to Make a Link Clickable in Email
- How To Create a Hyperlink in Word
- How Do You Make a Clickable Link with HTML?
- How to Add a Link to an Instagram Story?
- How to Add a Link to a YouTube Video Description?
- Happy Hyperlinking
HTML Links
Links are found in nearly all web pages. Links allow users to click their way from page to page.
HTML Links — Hyperlinks
HTML links are hyperlinks.
You can click on a link and jump to another document.
When you move the mouse over a link, the mouse arrow will turn into a little hand.
Note: A link does not have to be text. A link can be an image or any other HTML element!
HTML Links — Syntax
The link text is the part that will be visible to the reader.
Clicking on the link text, will send the reader to the specified URL address.
Example
This example shows how to create a link to W3Schools.com:
By default, links will appear as follows in all browsers:
- An unvisited link is underlined and blue
- A visited link is underlined and purple
- An active link is underlined and red
Tip: Links can of course be styled with CSS, to get another look!
HTML Links — The target Attribute
By default, the linked page will be displayed in the current browser window. To change this, you must specify another target for the link.
The target attribute specifies where to open the linked document.
The target attribute can have one of the following values:
- _self — Default. Opens the document in the same window/tab as it was clicked
- _blank — Opens the document in a new window or tab
- _parent — Opens the document in the parent frame
- _top — Opens the document in the full body of the window
Example
Use target=»_blank» to open the linked document in a new browser window or tab:
Absolute URLs vs. Relative URLs
Both examples above are using an absolute URL (a full web address) in the href attribute.
A local link (a link to a page within the same website) is specified with a relative URL (without the «https://www» part):
Example
Absolute URLs
W3C
Relative URLs
HTML Images
CSS Tutorial
HTML Links — Use an Image as a Link
To use an image as a link, just put the tag inside the tag:
Example
Link to an Email Address
Use mailto: inside the href attribute to create a link that opens the user’s email program (to let them send a new email):
Example
Button as a Link
To use an HTML button as a link, you have to add some JavaScript code.
JavaScript allows you to specify what happens at certain events, such as a click of a button:
Example
Tip: Learn more about JavaScript in our JavaScript Tutorial.
Link Titles
The title attribute specifies extra information about an element. The information is most often shown as a tooltip text when the mouse moves over the element.
Mastering the Art of Embedding Links with the and Tags in HTML
HTML links are an essential part of creating web pages that are easy to navigate and provide access to external resources. One of the most common ways to embed links in HTML is by using the link tag. In this blog post, we will guide you through the process of embedding links using the link tag in html .
Understanding the tag and the href attribute
Here is an example of how to create a basic hyperlink:
In the above code, the text “Click here to visit Example” is wrapped inside the tag, and the href attribute points to the URL of the page being linked.
It is important to note that the href attribute can also link to resources other than web pages, such as images, documents, and email addresses.
Using anchor links to navigate within a page
Anchor links are also called hyperlinks and can be used to link to another page or section within a page. Anchor links can be used to link to sections within the same page. The tag is an anchor tag in HTML, and it is used to create anchor links.
Here is an example of how to create an anchor link:
In the above code, the href attribute points to the ID of the section being linked to. To create the ID, add the attribute id=»section1″ to the section you want to link to.
Learn HTML link tag in just 6 minutes. How to insert links in HTML
How to create an HTML Link with the tag A. The A tag is an anchor tag in HTML. The HTML Duration: 6:37
Creating embedded links with anchor text
Embedded links use anchor text to create a link to another web page. HTML links are created using the tag, which indicates where the hyperlink starts and ends. The tag can also be used to create links to jump to a specific part of a page.
Here is an example of how to create an embedded link:
In the above code, the text “Visit Example” is the anchor text, and it is wrapped inside the tag. The href attribute points to the URL of the page being linked.
Bonus tips for creating and optimizing links
best practices for creating links include using descriptive anchor text and ensuring that links are easily visible. The latest advancements in HTML links include the use of rel=»noopener noreferrer” to improve security. Tips for optimizing links for seo include using descriptive anchor text and ensuring that links are relevant to the content on the page. cheatsheets for html links are available online and can be useful for quick reference. When creating links, it is important to use descriptive anchor text that gives users an idea of what they will find when they click the link. Links should also be easily visible and not hidden among other content. To improve security, it is recommended to use the rel=»noopener noreferrer” attribute when linking to external pages. This attribute prevents the linked page from accessing the window.opener object in the current page, which can be used for phishing attacks. When optimizing links for SEO, it is important to use descriptive anchor text that accurately reflects the content of the linked page. The links should also be relevant to the content on the page and not be used solely for the purpose of improving SEO.
How to Make a Hyperlink (Create Clickable Links in 3 Easy Steps)
Here you are, scratching your head and trying to figure out how to make a hyperlink.
Maybe you want to link to authoritative content from your new blog. Or perhaps you need a quick reminder on how to make a clickable link in HTML. Or, maybe you need to add a link to an Instagram Story or YouTube video.
Either way, we have you covered.
What Is a Hyperlink?
Hyperlinks are clickable words or images that navigate to other web content. They can connect with almost any resource on the web.
When clicked, they’ll either take you to a web address immediately or, for certain types of files, give you the option to open a document with an app (like Adobe Reader to open a PDF).
- Another web address (URL)
- Images, such as logos, icons, or graphics
- Audio files
- Videos
- HTML files
- Text files or other documents (PDFs, for example)
- A location within the same web page
Let’s look at a couple insert hyperlink methods.
How To Make a Hyperlink
Hyperlinks are fundamental to web navigation, and using them is second nature for most of us.
They show up in blog posts, word documents, PDFs, and emails.
Only when it’s time to embed a link in text do we give them any thought.
There are two ways to embed hyperlinks:
How Do I Make a Clickable Link in WordPress?
Let’s look at how to embed a link in text using the visual editor on your website:
- Highlight the anchor text you want to link.
- Click the Add Link icon within the text editing bar, or use the keyboard shortcut Ctrl+K. This opens a field where you’ll enter the location you want to create a link to.
- Enter the full address (including HTTPS) or existing file location you want the link to navigate to in the field, and press Enter.
Now you have a hyperlinked text.
How to insert links in images:
- Select the image by clicking on it.
- Now click the Add Link icon in the bar (or Ctrl+K) to open the field. Enter the location you want to link to (like our previous example).
In this example, I’ve linked to a PDF document stored on my Google Drive. Readers can open or download the page using an app of their choice.
The same process applies whether you’re editing a Post or a Page within WordPress.
How to Make a Link Clickable in Email
Here is how you create a email link in Gmail:
- Highlight the text you want to link.
- Click on the Add Link icon in the text editing bar (or Ctrl+K).
- Paste or type the URL you want to link to in the field and click ok.
Now you have your hyperlink.
The process is similar in Microsoft Outlook and other email clients.
How To Create a Hyperlink in Word
- To embed a link in text within a Microsoft Word document, start by highlighting the text.
- Then click Insert on the upper menu bar.
- Now click: Links → Link → Insert Link (a window will appear).
You can then add a URL to the Address field or link to:
- Another Microsoft Word document
- Another place on the same document
- Or an Email address
If you’re using another Microsoft Office program or Google Doc, the process is very similar. Highlight the text you’d like to turn into a hyperlink, go to Insert in the menu bar, and choose Link.
Then simply copy and paste the URL.
How Do You Make a Clickable Link with HTML?
When building a link in HTML, use the and elements to designate the beginning and end of the link.
Designate the target you’re linking to by using the href attribute:
As an example, let’s say you wanted to create the following:
This is what the HTML code would look like in the WordPress text editor:
For adding a hyperlink to an image, the basic snippet is:
To learn more about adding hyperlinks to images using HTML, check out this post.
How to Add a Link to an Instagram Story?
- On your mobile device, open the Instagram app.
- Tap the plus (+) icon at the top and select “Story”.
- Upload an image or video.
- Tap the sticker icon and select “Link”.
- Enter the URL you’d like the link in your Instagram Story to point to.
How to Add a Link to a YouTube Video Description?
- In YouTube Studio, go to the “Video details” for your video.
- In the “Description”, add your copy along with any hyperlinks you’d like viewers to be able to see.
Happy Hyperlinking
Now you know how to create multiple hyperlinks.
Most of the time you won’t need HTML and can simply link text by clicking the icon in the text editing toolbar.
Whether you’re creating a hyperlink on a web page to someone else’s blog or linking to a PDF or a podcast recording on your own site, now you have the information to create this fundamental element of web navigation.
Have fun with your new superpower!