DOM Snapshot
A captured copy of a page's document structure at a moment in time, used for comparison, debugging, or healing.
What is DOM Snapshot?
What is DOM Snapshot?
A DOM snapshot records the full structure of a page—its elements, attributes, and hierarchy—at a specific instant. Snapshots serve several jobs: comparing structure against a baseline to catch regressions, giving debuggers an exact view of the page when a test failed, and providing the context a healing engine needs to relocate an element whose selector changed. By understanding the surrounding structure rather than relying on a single brittle attribute, tools can recover locators automatically when a UI shifts.