Links
A link is a component which either takes users to a new web page or makes some changes to the current web page.
NOTE:
- New to accessibility or uncertain of requirements, it will be helpful to review all sections below.
- Already familiar with requirements, skip to the “Working Example” section for sample HTML, CSS and JavaScript (when needed), along with a working demo.
-
Link text MUST have sufficient color contrast with its background.
- Minimum requirement of 4.5:1 MUST be met for links having standard text size in default, focused and hover states.
- Minimum requirement of 3:1 MUST be met for links having larger text size i.e., 14pts with bold weight or more than 18 pts in default, focused and hover states.
- If an image is used to identify the link (e.g., home icon), then the color contrast requirement of 3:1 ratio MUST be met with the adjacent color for default, hover and focus states with the adjacent color.
- The contrast requirement of 3:1 ratio MUST be met with the adjacent colors for the custom focus indicator of the link.
- Links SHOULD be defined using
<a>
element. - Links should be navigable and operable through both the mouse and the keyboard.
Though ARIA CAN be used as an alternative, it is advisable to use correct semantic HTML element since native elements have built-in keyboard accessibility, roles and states.
-
Links CAN be defined using
role="link"
andtabindex="0"
attribute on the neutral containers such as<div>
,<span>
and so on. - Appropriate JavaScript event handlers MUST be used to make them.
- Displaying new tabs or windows without warning can be confusing to non-sighted, mobile, and screen reader users. Mobile devices give little indication a new tab or window has opened. Opening a new window or new tab can cause confusion for users who may not notice that this has happened.
-
Notify the user when links will open in new tabs or windows.
-
Avoid specifying a new window as the target of a link with
target="_blank"
. - If you cannot avoid displaying a new window, insert a warning into the link text like the following: "opens in a new window".
-
Avoid specifying a new window as the target of a link with
- The link text SHOULD be descriptive and unique to convey the purpose of the link.
-
Alternatively, the
aria-label
attribute CAN be used to provide a descriptive and unique accessible name. -
An off-screen text CAN be provided to make the accessible name descriptive
and unique.
- CSS can be used to place the text off-screen. For more information on placing text off-screen, visit https://css-tricks.com/comparing-various-ways-to-hide-things-in-css/ .
-
The accessible name SHOULD contain the visual text if available for the
link.
Note: If there is no visual label provided for the link, the accessible name can be provided as per the purpose. -
If an image is used to identify the link, then a textual description MUST
be defined for the image link.
- If the image is defined using <img> element, use an alt attribute with descriptive value.
-
If the image is defined using
<svg>
element, userole="img"
andaria-label
attribute to provide a role and an accessible name for the element.
Note: Providing ARIA based role and attribute on SVG image ensures robust support across different environments.
- The links that open content from a different website are called external links.
- href attribute SHOULD contain the URL of the target page.
- Descriptive link text SHOULD be given to the external links so that screen reader users should be aware of it opening in a new window or tab.
-
If the language of the new page is different from the current page, the target page’s
language should be specified with the
hreflang
attribute. For more information see the Language component. - The accessible name SHOULD consist of keyword such as “opens in a new window”.
Example,
<a href="#">Visit our legal offerings
<span class=”visually_hidden”>opens in a new window</span>
</a>
- Link text SHOULD clearly describe the purpose of the link. It helps screen reader users to understand the purpose of the link.
- Indeterminate link text such as “Learn More”, “Click Here”, “Get started”, and so on SHOULD NOT be given for the links as these do not explain the destination page it points to.
-
Link text CAN be made descriptive through one of the following.
- A hidden off-screen text describing the purpose of the link.
- Making the link text itself descriptive.
-
aria-labelledby
attribute CAN be used to associate the visual text with the link by referencing the id attribute of visual text container or visually hidden text container and the link itself. -
Concatenation of multiple pieces of text to form a name is possible through this
attribute by referencing the respective
id
attribute values. -
When using concatenation, the order of the
id
attribute value is important. -
id
attribute values SHOULD be present in the same HTML document. -
It CAN be specified in case of design constraint as well wherein an
additional visual text cannot be added for the link.
Example,
<h2 id="org">Organization</h2> ... <a id="primary" href="#" aria-labelledby="primary org">Explore More</a>
Note: If both link text and
aria-labelledby
oraria-label
andaria-labelledby
or link text,aria-label
andaria-labelledby
are present, thearia-labelledby
will take precedence to convey the accessible name of the link. -
aria-label
attribute CAN be used to define a label for the link that does not have supporting visual label. - It’s a challenge for internationalization because its value will not get translated and will require manual updating.
- It’s also a challenge for providing name wherein the name MUST be updated as these are hardcoded values.
-
It’s not visible on-screen so ONLY helps assistive technology users such as screen
reader users.
Example,
<a href="#" aria-label="Explore more about organization">Explore More</a>
-
aria-describedby
attribute CAN be used to associate the additional information with the respective button by referencing theid
attribute of visual text container or visually hidden instruction text container. -
This attribute MUST NOT be used as a sole method for naming the link.
Example,
<h2 id="org">Organization</h2> ... <a href="#" id="primary" aria-describedby="primary org">Explore More</a>
- Link text SHOULD NOT contain role information such as “link”, “icon” and so on as a part of it so that screen reader users do not have to listen to redundant information.
- The text “Opens in a new window” CAN be given as a part of the link text.
- Links given within paragraphs CANNOT be identified as links by low vision and color-blind users.
- Only color MUST not be used to distinguish the links from the surrounding text of the paragraph in which the link is present.
- The foreground color of link text SHOULD meet the color contrast ratio requirement of 3:1 with the surrounding text color.
- In addition to this, a visual cue like underline, bold formatting, or icons CAN be used to help distinguish the links from the surrounding text.
Links that open PDFs are usually provided on websites. These links either open PDFs in a new window when activated or downloads the PDF. It is necessary to inform screen reader users that these links open PDFs in a new window.
Implementing PDF links
- Link opening a PDF SHOULD contain an icon indicating the same.
- This icon SHOULD contain descriptive alternative text informing the users of the PDF opening in a new page.
- The link text SHOULD be clear enough to indicate the type of target it is opening (for example – new webpage, downloadable PDF and so on).
- The size of PDF CAN also be specified within the link text.
-
The downloadable PDFs SHOULD be in accessible format.
For example,<a onclick="showDownloadStartedMessage()" href="/accessibility-conformance-reporting/ACRs/AccessibleABBI_ACR_VPAT2.4RevWCAG(March2022).pdf" download="Pearson ABBI ACR, based on ITI WCAG 2.4 VPAT"> <i class="fa fa-download" aria-label="Download" role="img"></i> ABBI ACR, based on ITI WCAG 2.4 VPAT (PDF) - (450kb) </a>
A well-defined link benefits majorly the below users.
- People with cognitive disabilities
- People with visual disabilities
- People using speech input
- People with limited dexterity
- People using keyboard only
<div class="container mt-4">
<h2>External link</h2>
<h3>Governance Download Centre</h3>
<p>Explore our key corporate documentation in our download centre.</p>
<a href="https://plc.pearson.com/en-GB/company/governance/governance-download-centre" target="_blank" class="button-primary new-window" onclick="window.open('https://plc.pearson.com/en-GB/company/governance/governance-download-centre','name','width=600,height=400')">
<span>explore more about the</span>Governance Download Centre<span>Opens in a new window</span>
</a>
</div>
<div class="container mt-4">
<h2>Purpose Link</h2>
<h3>Our Targets & KPIs</h3>
<p>
As we implement our new strategy for growth, see how we're
aligning the goals we set and the way we measure our progress.
</p>
<a target="_self" class="button-primary" href="https://plc.pearson.com/en-GB/purpose/our-targets-kpis" role="link" tabindex="0">
<span>explore more about the</span>REVIEW OUR TARGETS AND KPIs
</a>
</div>
<div class="container mt-4">
<h2>Underline Link</h2>
<h3>Our guidelines for accessible educational web media</h3>
<p>
We gratefully acknowledge and endorse the work of the Web
Accessibility Initiative of the World Wide Web consortium on the
Web Content Accessibility Guidelines (WCAG) 2.1, as well as the
work of United States Access Board and the Information Technology
Advisory Committee (TEITAC) on their Section 508 Refresh Drafts.
We strive to provide equal access for all students. To achieve
this goal, we've created the
<a class="underline" href="https://www.pearson.com/accessibility-guidelines.html">
Pearson Accessibility Guidelines for eLearning
</a>. These guidelines provide developers standards for creating
the most effective educational content.
</p>
</div>
<div class="container mt-4">
<h2>Same Name Link</h2>
<div class="row">
<div class="column">
<h2 id="Learners-heading">
She Will Find a Way: Women Across the Globe Navigate the
Ever-Changing Job Market
</h2>
<p>
We asked 6,000 women in six countries how the challenges
of COVID-19 have impacted their lives, their careers, and
their communities. The results show that many women are
optimistic about their prospects and forging ahead to
overcome barriers to success.
</p>
<a class="button-primary" target="_blank" id="Learners-explore-link" aria-labelledby="Learners-explore-link Learners-heading" href="https://plc.pearson.com/sites/pearson-corp/files/pearson/future-of-learning/global-learner-survey/women-in-workforce/gls-2021-women-in-workplace-one-pager.pdf">
Full Report<span>about </span>
</a>
</div>
<div class="column">
<h2 id="educators-heading">
Tough Lessons: Learners Want More Education on Social
Justice and Equity Issues
</h2>
<p>
As issues of social justice become more present and urgent
in our world, Pearson asked 5,000 people globally, to
examine what they learned, and what they need to learn,
when it comes to race and gender equality.
</p>
<a class="button-primary" target="_blank" id="educators-explore-link" aria-labelledby="educators-explore-link educators-heading" href="https://plc.pearson.com/sites/pearson-corp/files/pearson/future-of-learning/global-learner-survey/gls-2021-equity-one-pager-global.pdf">
Full Report<span>about the</span>
</a>
</div>
<div class="column">
<h2 id="practitioners-heading">
How a pandemic is forging a stronger generation of young
learners
</h2>
<p>
As people begin to emerge from the COVID era, learning and
personal growth have been an unexpected silver lining on
these dark days. We asked 6,000 college students and
parents of school age children in four countries how young
people think about themselves, their careers, and their
communities. The results show how much people are learning
from one of the hardest lessons the modern world has
faced.
</p>
<a class="button-primary" target="_blank" id="practitioners-explore-link" aria-labelledby="practitioners-explore-link practitioners-heading" href="https://plc.pearson.com/sites/pearson-corp/files/pearson/future-of-learning/global-learner-survey/2021/gls-2021-one-pager-pandemic.pdf">
Full Report<span>about</span>
</a>
</div>
</div>
</div>
body {
font-family: Arial, sans-serif;
line-height: 1.6;
}
.column {
width: 100%;
padding: 10px;
box-sizing: border-box;
border-top: 6px solid;
border-color: #0086b1;
}
a.new-window { position: relative; }
a.new-window::after {
position: absolute;
top: 18px;
right: 5px;
content: "\1f855";
font-size: 14px;
color: white;
line-height: 3px;
height: 7px;
width: 7px;
border-right: 2px solid #ae367e;
border-top: 2px solid #ae367e;
}
a.new-window::before {
position: absolute;
top: 18px;
right: 6px;
content: " ";
border: 1px solid white;
width: 11px;
height: 11px;
}
.button-primary {
background-color: #ae367e;
color: #fff;
padding: 13px 25px;
font-size: 16px;
text-transform: uppercase;
text-decoration: none !important;
border-radius: 2px;
display: inline-block;
margin-top: 20px;
font-weight: 700;
position: relative;
overflow: hidden;
letter-spacing: 0.5px !important;
}
a.button-primary span {
position: absolute;
left: -9000px;
width: 0;
overflow: hidden;
}
External link
Governance Download Centre
Explore our key corporate documentation in our download centre.
explore more about theGovernance Download CentreOpens in a new windowPurpose Link
Our Targets & KPIs
As we implement our new strategy for growth, see how we're aligning the goals we set and the way we measure our progress.
explore more about theREVIEW OUR TARGETS AND KPIsUnderline Link
Our guidelines for accessible educational web media
We gratefully acknowledge and endorse the work of the Web Accessibility Initiative of the World Wide Web consortium on the Web Content Accessibility Guidelines (WCAG) 2.1, as well as the work of United States Access Board and the Information Technology Advisory Committee (TEITAC) on their Section 508 Refresh Drafts. We strive to provide equal access for all students. To achieve this goal, we've created the Pearson Accessibility Guidelines for eLearning . These guidelines provide developers standards for creating the most effective educational content.
Same Name Link
She Will Find a Way: Women Across the Globe Navigate the Ever-Changing Job Market
We asked 6,000 women in six countries how the challenges of COVID-19 have impacted their lives, their careers, and their communities. The results show that many women are optimistic about their prospects and forging ahead to overcome barriers to success.
Full ReportaboutTough Lessons: Learners Want More Education on Social Justice and Equity Issues
As issues of social justice become more present and urgent in our world, Pearson asked 5,000 people globally, to examine what they learned, and what they need to learn, when it comes to race and gender equality.
Full Reportabout theHow a pandemic is forging a stronger generation of young learners
As people begin to emerge from the COVID era, learning and personal growth have been an unexpected silver lining on these dark days. We asked 6,000 college students and parents of school age children in four countries how young people think about themselves, their careers, and their communities. The results show how much people are learning from one of the hardest lessons the modern world has faced.
Full Reportabout<h2>Pearson Accessibility Conformance Report</h2>
<p> Download: </p>
<a onclick="showDownloadStartedMessage()"
href="https://github.com/nikhilm-10/component-library-file/raw/main/PearsonAccess_Next_Accessibility_Conformance_Report_VPAT2.4Rev508.pdf"
download="Pearson Accessibility Conformance Report Revised Section 508 Edition.pdf">
<i class="fa fa-download" aria-label="Download" role="img"></i>
PearsonAccess Next Accessibility Conformance Report VPAT 2.4 Rev 508
(PDF) - (415kb)
</a>
h1 {
font-weight: 700;
line-height: 1.2;
color: #005A70;
}
h2 { color: #005A70; }
a { color: #005a70; }
body {
font-family: 'Arial', sans-serif;
text-align: center;
margin: 50px;
}
Pearson Accessibility Conformance Report
Download:
PearsonAccess Next Accessibility Conformance Report VPAT 2.4 Rev 508 (PDF) - (415kb)