Skip to content
Bugwise
Menu
UI Components

Tooltip

A small text bubble that explains a control on hover, focus or long-press. Learn why touch screens have no hover, the WCAG rules for content on hover or focus, edge collisions, and why an icon button still needs its own name.

35 min Feedback & overlays iOS · Android · Web Also called: Popover hint, Info tip, Coachmark (related)

You’re sending rent from your banking app on your phone. Next to IBAN there’s a little ⓘ. You tap it. Nothing. You tap it again, harder. Still nothing. On the laptop the same ⓘ shows a helpful bubble, but only when the mouse is over it. The developer tested with a mouse, and never noticed that phones don’t have one.

Tooltips look like the most harmless component on the page: a few words in a dark bubble. But they depend on how the user points at things (mouse, finger, keyboard, screen reader), they float over other content, and they love to hide behind screen edges. That makes them a great place to find bugs.

What is a tooltip?

A tooltip is a small, temporary bubble of plain text that describes the element it’s attached to. It appears when the user hovers over the element with a mouse, moves keyboard focus to it, or (on touch screens) long-presses it. It disappears when they move away.

You’ll usually see tooltips used to:

  • Name icon-only buttons: Archive, Share, Add to wishlist.
  • Show keyboard shortcuts: Bold (Ctrl+B).
  • Add a short hint next to a form label: “Shown on the recipient’s statement”.
  • Show the full text of something that is cut off, like a long file name.

Anatomy

A web tooltip on a focused icon button

  1. 1

    Trigger

    The element the tooltip explains, often an icon button. It must be focusable and have its own accessible name.

  2. 2

    Container

    A small bubble, usually dark with light text. It floats above the page and never pushes content around.

  3. 3

    Text

    A short, plain-text hint: a few words, no links, no buttons. If it needs more, it is a popover.

  4. 4

    Arrow (caret)

    Optional. Points at the trigger, so it stays clear what the hint belongs to, even after shifting at screen edges.

  5. 5

    Offset

    The small gap to the trigger. The pointer must be able to cross it without the tooltip disappearing.

Tooltip, toggletip, toast or inline help?

Several components show “a bit of extra text”. Picking the wrong one is one of the most common tooltip problems.

PatternOpens whenContentGood for
TooltipHover, focus, long-pressA few words of plain textNaming icons, shortcuts
Toggletip / popoverClick or tapText, links, buttonsExplanations, “Learn more”
ToastThe app shows it after an actionA status message, maybe “Undo”“Transfer sent”
Inline helpAlways visibleText under a fieldRules users need to succeed
CoachmarkOnce, during onboardingTitle, text, close buttonPointing at a new feature

Designs & variants

Try each one with the mouse, with only the keyboard (Tab, Esc), and on a phone (press and hold the Android icons).

Your order has shipped

Nordic Home · 09:14

Tooltip on icon buttons

Web

Hover with a mouse (short delay) or Tab with the keyboard (instant). Esc hides it. The button has its own name; the tooltip only shows it.

Hover + focusEscShortcut hint

Trail runner 2

Plain tooltip

Android

Material 3 plain tooltips appear on long-press (or mouse hover) and name icon-only buttons. They disappear by themselves after release.

Long-pressInverse surfaceNo arrow

Instant transfer

+€0.50

Money arrives in seconds

Toggletip (info popover)

Web

Opens on click or tap, stays until closed, and may hold a link. Strictly speaking it is a small popover, not a tooltip.

Click / taparia-expandedEsc returns focus

Notes

Tip / coachmark

iOS

Onboarding tips (like Apple's TipKit popover tips) point at a feature once. They need a clear close button and must not come back after dismissal.

OnboardingClose buttonShow once

Hover, focus, long-press: touch screens have no hover

A tooltip has to work for every way people point at things. This is where most tooltip bugs come from.

InputHow the tooltip should openHow it should close
Mouse / trackpadHover, after a short delayPointer leaves (trigger and tooltip), or Esc
KeyboardTab focus, immediatelyFocus moves on, or Esc
Touch (Android)Long-press the icon buttonShortly after the finger lifts
Touch (iPhone, web)Usually not at all, so don’t hide anything important in itn/a
Screen readerNever “opens”; the text is read as the name or descriptionn/a

The key lesson: on a phone, a hover-only tooltip doesn’t exist. A tap is not a hover. If the information matters on mobile, it must be visible, or opened with a tap as a toggletip.

Delay and dismissal: WCAG 1.4.13

Mouse tooltips usually wait a few hundred milliseconds before appearing, so they don’t flash while the pointer crosses the page. Keyboard focus should show them right away.

Once a tooltip is visible, WCAGWCAGThe Web Content Accessibility Guidelines, the main international standard for accessibility.Open in glossary → success criterion 1.4.13 Content on Hover or Focus (level AA) asks for three things:

  1. Dismissible. The user can hide it without moving the pointer or focus, usually with Esc. A tooltip that covers the next field must not force the user to move away.
  2. Hoverable. The user can move the pointer onto the tooltip without it disappearing. People who use screen magnifiers need this to read it.
  3. Persistent. It stays until the user moves away, dismisses it, or it’s no longer relevant. No timer that hides it after two seconds while the pointer is still there.

Positioning and screen edges

A tooltip normally appears above (or below) its trigger, centered. Near an edge there is no room, so a good tooltip:

Test the first and last icon in every toolbar, at the narrowest viewportViewportThe visible area of a web page in the browser window or on the device screen.Open in glossary → and with long translations.

Plain text only

A tooltip disappears when the pointer or focus leaves the trigger, so anything interactive inside it is a trap: a mouse user has to “chase” the link, a keyboard user can’t Tab into it, and a touch user never sees it. If the bubble needs a link or a button, it should be a toggletip or popover that opens on click and stays open.

Icon buttons still need a name

A tooltip that says “Delete” looks like the button’s name, but a screen readerScreen readerSoftware that reads the screen aloud for blind and low-vision users, like VoiceOver or TalkBack.Open in glossary → only uses it if the code connects them. An icon button needs an accessible name of its own. Otherwise it’s announced as just “button”. The tooltip is the visual version of that name, not a replacement for it.

Dev note
aria-label="Delete" on the web, accessibilityLabel on iOS, contentDescription on Android.

Onboarding coachmarks

Coachmarks (or “tips”) point at a feature the first time a user sees a screen: “Tap here to start a new note”. They’re related to tooltips, but appear without hovering. Test that they:

  • Have a clear close button (with a name) and close with Back / Esc.
  • Don’t come back after being dismissed, after a restart or an update (unless that’s the plan).
  • Point at the right thing, on every screen size and in landscape.
  • Don’t block the very button they’re pointing at, and don’t stack three on top of each other.

When to use it

Tooltips are a good choice when:

  • You need to name an icon-only button for mouse and keyboard users (and the button already has an accessible name).
  • The hint is nice to know, not need to know: the user can succeed without ever seeing it.
  • The text is short: a few words, one short sentence at most.
  • The product is used with a mouse or keyboard (desktop web, tablets with a pointer), or on Android, where long-press shows it.

Good and bad uses

Rules visible under the field

Users read the rules before they type, on every device.

Rules hidden in a tooltip

On a phone the ⓘ does nothing, so users only learn the rules from the error. Need-to-know information belongs on the page.

A few words of plain text

Names an icon. Nothing to click inside.

Links and buttons in a tooltip

“Learn more” and “Got it” are hard or impossible to reach. Use a toggletip or popover that opens on click and stays open.

Common bugs

#BugWhat you seeSeverity
1Hover onlyNothing on Tab, nothing on tapMedium–High
2Clipped at the edgeHalf the text is cut off near the screen edgeMedium
3Not hoverableIt vanishes when the pointer moves towards itMedium (fails WCAG)
4Can’t dismissEsc does nothing; it covers the next fieldMedium (fails WCAG)
5Interactive contentA “Learn more” link that can’t be clicked or reachedMedium
6Icon button with no nameScreen reader says just “button”High (for affected users)
7Sticky tooltipStays on screen after scrolling, closing a dialog or tapping elsewhereLow–Medium
8FlickerTooltips flash on and off while the mouse crosses a toolbarLow
9Wrong or stale text“Mark as read” on a message that’s already readMedium
10Coachmark returnsA dismissed onboarding tip shows up again after every restartLow–Medium

Stress-test it

This mail app toolbar has correct tooltips. Use the settings to break them on purpose and watch the WCAG check. Try it with the mouse, then only with the keyboard, then on your phone.

Hover delay
Hoverable
Esc closes
Edge handling

Your order has shipped

Nordic Home <orders@nordic.example> · 09:14

Hi Anna, good news: order #4821 is on its way. Track it with DHL using the code JJD0099 1234 5678.

Mouse: hover · Keyboard: Tab, then Esc · Touch: press and hold

WCAG 1.4.13 check

  • Dismissible. Esc hides it without moving the pointer or focus.
  • Hoverable. You can move the pointer onto it (e.g. to zoom in on it).
  • Persistent. Stays until the pointer leaves, focus moves or Esc. No timer.

Screen reader would say

Tab to a toolbar button to hear it…

Event log

  • Hover, Tab or long-press a button.

Things to try: turn Edge handling off and hover Archive and Snooze at the edges. Turn Hoverable off and try to move the pointer onto the long Mute tooltip. Set the delay to 0 and sweep the mouse across the toolbar: tooltips flash on and off. Tab to a button: keyboard focus never waits for the delay.

Find the bug

This “Send money” page in a web bank has six tooltip bugs. Explore it like a tester:

  • Use the mouse on every icon: hover, then try to move onto the bubble.
  • Then use only the keyboard: Tab through the page and press Esc when something covers the form.
  • Open the ? next to Instant transfer and try its link.
  • Read the screen reader panel for every button.
  • If you can, open this page on a phone and tap the info icons.

🐞 Bug hunt: Send money

This demo has 6 hidden bugs. Explore it like a tester, then check your findings.

Found0/6
bank.example.com/transfer

Send money

From Main account€1,240.50
Instant transfer
Fee€0.00

Tester tools

Screen reader would say

Tab through the page to hear each control…

Test with the mouse, then only the keyboard (Tab, Esc). On a phone, tap the info icons.

  1. 1

    Hint: Tab to the ⓘ next to IBAN, or tap it on a phone.

  2. 2

    Hint: Hover the ⓘ next to the fee at the right.

  3. 3

    Hint: Hover the ⓘ next to Reference and move the mouse up onto the bubble.

  4. 4

    Hint: Click into Amount, then press Esc. Then try to click the Reference field.

  5. 5

    Hint: Open the ? next to Instant transfer and click the link. Then try to reach it with Tab.

  6. 6

    Hint: Tab to the QR icon at the top and read the screen reader panel.

How to test it

Checklist

Tooltip test checklist

0 of 13 checked

Example test cases

TC-TIP-001Tooltip opens on keyboard focus

Steps

  1. Open the Send money page
  2. Press Tab until the ⓘ next to "IBAN" has focus

Expected result

The IBAN tooltip appears immediately next to the icon, and the focus ring is visible.

TC-TIP-002Esc dismisses a tooltip

Steps

  1. Hover the ⓘ next to "Fee" until the tooltip appears
  2. Without moving the mouse, press Esc

Expected result

The tooltip disappears. The pointer and focus stay where they were. It does not reappear until the pointer leaves and comes back.

TC-TIP-003Tooltip is hoverable

Steps

  1. Hover the ⓘ next to "Reference"
  2. Move the pointer slowly onto the tooltip text
  3. Wait 10 seconds

Expected result

The tooltip stays visible the whole time, and hides only after the pointer leaves both the icon and the tooltip.

TC-TIP-004Tooltip near the right edge stays on screen

Preconditions

  • Browser window 360 px wide (DevTools device toolbar)

Steps

  1. Hover the right-most ⓘ (Fee)
  2. Repeat with the longest supported translation

Expected result

The whole tooltip is visible inside the viewport; its arrow still points at the icon.

TC-TIP-005Information is available on touch devices

Preconditions

  • Real phone (iPhone and Android)

Steps

  1. Open the Send money page
  2. Tap each ⓘ icon

Expected result

Each tap shows the information (as a toggletip or inline text). Nothing important is available only on hover.

TC-TIP-006Icon button has an accessible name

Preconditions

  • VoiceOver, TalkBack or NVDA on

Steps

  1. Move to every icon-only button on the page

Expected result

Each one is announced with a meaningful name, e.g. "Scan QR code, button". None is announced as just "button".

TC-TIP-007Long-press tooltip on Android

Preconditions

  • Android app with icon buttons in the top app bar

Steps

  1. Long-press the "Share" icon
  2. Lift the finger

Expected result

A tooltip "Share" appears during the long-press and disappears shortly after the finger lifts. The share sheet does not open.

TC-TIP-008Coachmark stays dismissed

Preconditions

  • Fresh install

Steps

  1. Open Notes; the "Start a new note" tip appears
  2. Close it with the X
  3. Force-quit and reopen the app

Expected result

The tip does not appear again.

Tip: click a test case to expand it.

Tools

  • DevTools › Elements: right-click › Force state › :hover or :focus keeps CSS tooltips open while you inspect them. For JavaScript tooltips, use Emulate a focused page (Rendering panel) so they don’t close when you click into DevTools.
  • Accessibility pane: shows each button’s computed Name and Description. An empty name on an icon button is bug #6.
  • Device toolbar: test at 360 px wide and with touch emulation. Remember that emulation is not a real finger: confirm touch behavior on a real deviceReal deviceA physical phone or tablet used for testing, as opposed to an emulator or simulator.Open in glossary →.
  • Screen readers: VoiceOver (Mac and iPhone), TalkBack (Android), NVDA (Windows, free).

Accessibility

  • Name first. Every icon-only button needs an accessible name.
    Dev note
    On the web that’s aria-label (or a tooltip linked with aria-labelledby). On iOS it’s accessibilityLabel; on Android, contentDescription. For Android toolbar menu items, the item’s title usually serves as both the spoken name and the long-press tooltip.
  • Link extra text as a description. A screen reader reads a tooltip that adds information after the name.
    Dev note
    The tooltip gets role="tooltip" and is referenced with aria-describedby from the trigger.
  • Never rely on title. The native title tooltip doesn’t show on keyboard focus or touch, can’t be styled, and screen readers handle it inconsistently.
  • KeyboardKeyboard navigationUsing a website with only the keyboard: Tab to move, Enter or Space to activate, Esc to close.Open in glossary →. The trigger must be focusable; focus shows the tooltip, Esc hides it, and focus never moves into a tooltip. If users need to Tab into it, it’s a popover.
  • WCAG 1.4.13. Dismissible, hoverable, persistent (see above). This is a level AA criterion, so most accessibility audits check it.
  • Contrast and size. Tooltip text needs 4.5:1 contrast against its bubble, and must still fit at 200% zoom and the largest text size.

Mobile vs web

  • iPhone apps rarely use tooltips: there’s no hover, and Apple’s guidelines prefer clear labels and standard icons. Icon buttons still need a label for VoiceOver.
    Dev note
    That’s accessibilityLabel.
  • On the Mac (including Mac Catalyst apps), apps can show a hover tooltip; on iPad with a trackpad or mouse, check what the app’s iPadOS version actually shows.
    Dev note
    SwiftUI’s .help("…") shows the hover tooltip.
  • For feature hints, apps use TipKit (iOS 17+): popover tips and inline tips. Test that they close, stay closed, and don’t cover what they point at.
  • Larger hints usually live in a popover or a bottom sheet.
  • Android has built-in tooltips. They appear on long-press and on mouse hover.
    Dev note
    android:tooltipText, TooltipCompat; TooltipBox with PlainTooltip / RichTooltip in Compose.
  • Action bar / toolbar icons show their title as a tooltip on long-press. Check that the long-press doesn’t also trigger the action.
  • Material 3 rich tooltips can include a title and an action; persistent ones stay open until dismissed. Test them like popovers.
  • Test with TalkBack: icon buttons must have a description.
    Dev note
    That’s contentDescription.
  • Test hover, focus and touch. Use real phones; mobile browsers have no hover, and taps can “stick” a hover state.
  • Check edges, scrolling containers and zoom: the tooltip must stay visible and move with its trigger.
  • Inspect the markup: role="tooltip", aria-describedby or aria-labelledby, no interactive content, no reliance on title.
    Dev note
    Newer HTML features like the Popover API (popover attribute) help build toggletips and popovers that open on click and close with Esc.

Check your understanding

Quick quiz

0/5 answered · 0 correct

  1. 1.The ⓘ next to "IBAN" works with a mouse on desktop. What is the most important thing to test next?

  2. 2.Which of these belongs in a tooltip?

  3. 3.A tooltip disappears as soon as you move the mouse towards it. Which WCAG 1.4.13 requirement fails?

  4. 4.An icon button shows the tooltip "Delete", but VoiceOver says only "button". What is missing?

  5. 5.How do Android apps usually show the tooltip of a toolbar icon button?

Key takeaways

  • A tooltip is a short, plain-text hint that appears on hover, keyboard focus or long-press. Links and buttons belong in a toggletip or popover.
  • Touch screens have no hover. Never hide need-to-know information in a hover-only tooltip.
  • WCAG 1.4.13: tooltips must be dismissible (Esc), hoverable and persistent.
  • Test the edges: tooltips must shift or flip, never get clipped.
  • Every icon button needs its own accessible name. The tooltip is just the visible version of it.

Finished this page?Nice work, this page is complete!

Mark it as done to track your progress. It's saved in this browser, no account needed.

Its review cards are now in Bites ⚡
Esc

Type to search the whole site.