Self-Healing Locators
Self-healing locators automatically adapt when a UI element's original locator breaks — a changed CSS class, a moved ID — by using heuristics or AI to find the same logical element through alternate attributes, instead of the test simply failing. It's a targeted fix for one of automation's most common maintenance burdens.
Modern self-healing tools typically capture multiple candidate attributes for an element when a test is first recorded — its ID, class, text content, position, surrounding structure — so that if one signal (say, the ID) changes, the tool can still recognize the "same" element using the others, and often flags the drift for a human to confirm rather than silently guessing forever.
It doesn't eliminate the need for a good locator strategy — a well-chosen `data-testid` still breaks far less often than anything self-healing needs to compensate for — but it meaningfully reduces the maintenance tax on large suites where UI churn is constant and manual selector fixes eat real engineering time.