# Skip link

## What it is

A skip link is a link that lets a reader move directly past a repeated part of a page. A common example is a Skip to main content link near the beginning of a document. When a person activates it, the browser takes them to a named destination in the same page. The reader can then start reading and moving through the main content without passing each repeated header control.

The link relies on an actual destination. On a page linking to `#main`, the main region can carry `id="main"`. That identifier should be unique and stable, so the link continues to work as other parts of the page change. Test where the browser scrolls and where keyboard navigation resumes. The link's purpose is a usable shortcut, so checking only that its destination exists leaves important behaviour unmeasured.

A site can show the link all the time or reveal it when it receives focus. In either case, a keyboard user needs to see it when they can operate it. Keep its appearance predictable and its wording clear. Use a link whose visible and accessible text identifies the content it reaches.

## Why it matters

A header can contain a language picker, service links, contact options and a menu. A keyboard user may reach its controls in turn while visiting every article on the site. These controls are useful when the person needs them. The same controls become repeated work when the person wants to read the next page. A skip link lets the reader decide how much of the header to pass through.

The link also helps when a layout changes. A long menu can be compact visually but still contain many focusable elements when it opens. Some readers begin a visit at the top of the document after moving between pages. A predictable shortcut near that point makes the page's reading path easier to learn across templates and languages.

The design should preserve a clear distinction between starting to read and operating a control. When a skip link jumps to a heading, place the reader somewhere that identifies the content they reached. Make the next key move predictable. A destination that is scrolled into view but leaves subsequent keyboard navigation in the header can slow the task despite an apparently successful jump.

## What it looks like in practice

Open a long page with a header and navigation. Begin with no pointer interaction and press Tab from the start. Confirm the skip link is reached early and is visible. Activate it and observe the main region and the next key movement. It should be possible to continue with the first relevant content control or follow the natural browser sequence from the chosen destination.

Repeat the test with a short viewport and fixed navigation. A sticky bar might cover the destination even when the browser scrolls to its identifier. Check the start of the main region and the visible location after the next Tab. An offset or an appropriately placed heading can help preserve the destination's context. Test the result in layouts that rearrange the header as the viewport changes.

Engineer's accessibility statement records that a real Tab check verifies the first stop links directly to the content. It also describes checking that focus is visible and unobscured. That approach supplies a useful practical test for a skip link. The rendered shortcut should work even if the header becomes visually larger in one of the site's languages.

Test a page with very short main content too. A link should still give a meaningful destination and leave the next action obvious. Compare normal navigation and shortcut navigation to make sure the user can choose the path that suits the task on each template.

## Where it goes wrong

A skip link can be visually hidden in a way that removes it from interaction. Make it visible when focused if it is otherwise positioned out of view. Check that it is above any author-controlled layer that might cover it. Test the text and focus treatment in different colour themes and after zoom so the link can be recognised during a real visit.

A destination can disappear when a page template changes, or several fragments can end up sharing the same identifier. The browser may scroll to an unintended target. Keep a common destination strategy across page types and use a rendered navigation test to verify which element the link reaches. Include error and list pages if they share the overall header.

Some page shells expose several useful regions. A long tool could provide one link to its main work area and another to results. Choose multiple shortcuts only when they lead to genuinely different tasks. Give each a distinct destination and test the order in which they first appear. Repeated links with similar labels can create another set of stops before the reader reaches the part they wanted.

Also follow navigation into and out of related pages. A fragment identifier in a bookmarked URL can lead directly to the main region. The linked heading should still make sense once it is reached this way. Check how the page behaves when the reader follows a normal article link afterward.

Finally, observe more than the initial jump. The reader should be able to continue using the keyboard and find related controls within the content. If a page has more than one useful shortcut, make their destinations distinguishable. A good test records the source link, the destination and the next interactive state so the team can reproduce the shortcut even after changes to layout.

## Further reading
* WCAG Bypass Blocks. Describes ways to bypass repeated sections.
* WAI technique for linking to main content. Explains and illustrates the skip-link technique.
* The HTML Standard on navigating to fragments. Defines how the browser navigates to an in-page destination.

=> /accessibility/ accessibility statement
=> https://www.w3.org/WAI/WCAG22/Understanding/bypass-blocks.html WCAG Bypass Blocks
=> https://www.w3.org/WAI/WCAG22/Techniques/general/G1 WAI technique for linking to main content
=> https://html.spec.whatwg.org/multipage/browsing-the-web.html#scroll-to-fragid The HTML Standard on navigating to fragments

=> https://engineer.company/glossary/skip-link/ This page on the web
