Descriptive Link Text | Accessible Technology | Michigan Tech (original) (raw)

When adding text-based links within a webpage, carefully choose which words to hyperlink. The general rule of thumb is to always link keywords. Linking keywords will:

Linked text should make sense out of context. This is because screen readers often navigate from link to link, skipping the surrounding text. They will read each link out loud, in sequential order.

For example, if your link text is "Copper Country," then the screen reader will say "link Copper Country" and the user will know that the webpage being linked to is likely about the Copper Country. If instead, your link text is "click here," the screen reader will say link click here and the user will have no idea what the linked webpage may be about.

Good Example

_<p>_Michigan Tech and the **<a href="/tour/copper-country/">**Copper Country**</a>** have a small-town feel. Students and community members say it's just right—not so big that it's easy to get lost, but not too small, either. An ideal place to call home._</p>_

Bad Example

_<p>_Michigan Tech and the Copper Country have a small-town feel. Students and community members say it's just right—not so big that it's easy to get lost, but not too small, either. An ideal place to call home. **<a href="/tour/copper-country/">**Click here**</a>** to learn more._</p>_

Another feature that screen reader users may take advantage of is the ability to order page links alphabetically. This is particularly useful if the user already has a specific link in mind, such as a contact form or staff listing. It is important to keep the most important keywords at the beginning of your link text. "Staff listing" will appear alphabetically as expected. "View our staff listing" will not.

Use the following tips to ensure that link text is accessible:

Linking Images

For some webpages, it may be appropriate to link an image to a webpage instead of linking text. In these instances, the screen reader will read the image's alternative text (ALT tag) as the link text. The ALT tag must include both the content and function of the image. If the image is decorative, then only function is necessary.

Decorative Image Example

_<p><a href="/tour/copper-country/"><img src="my-picture.jpg"_ **alt="Staff Listing"** _/></a></p>_

Informational Image Example

_<p><a href="/tour/copper-country/"><img src="my-picture.jpg"_ **alt="Diagram showing 200 inches of total snow; linking to monthly subtotals"** _/></a></p>_

Optional Programming Techniques

There may be instances where you want to keep general link text, such as "[read more]." In these instances you can use aria-label or aria-labelledby to give link context to screen readers.

aria-label Example

Most screen readers will read out loud the aria-label attribute in place of the link text. For instance, a "read more" link related to the Copper Country can be coded as follows:

_<p class="right"><a href="/tour/copper-country/" **aria-label="Copper Country"**>_[read more]_</a></p>_

aria-labelledby Example

There may be instances where a nearby headline can act is the perfect label for a general link. In this case, you can connect that headline to the general link by usingaria-labelledby.

`<h2 **id="copper-country"**>The Copper Country

Michigan Tech and the Copper Country have a small-town feel. Students and community members say it's just right—not so big that it's easy to get lost, but not too small, either.

<a href="/tour/copper-country/" **aria-labelledby="copper-country"**>[learn more]

`

Instead of saying "link, learn more," the screen reader will say "link, Copper Country."

Using a screen reader to speak each link on your webpage is the best testing you can do. However, if you do not have access to a screen reader, read the linked text out loud for each of your links. Would someone who you are reading to understand what content you are linking to based only on the linked words spoken?

Learn More

To learn more about descriptive link text:

Modern Campus CMS

To create a link within the content of your webpage, highlight your text or image and then click the link icon in the toolbar or use the shortcut Cmd/Ctrl + K.

To add an aria-label or aria-labelledby attribute, navigate to source code using the toolbar.

To add an image with alternative text to your page body, read step four under Insert Image. To modify alternative text of an image already within the body of your webpage, select the image and then click the "Insert/Edit Image" button from the toolbar.