Auto-waiting: what Playwright checks before it acts
Before it clicks or types, Playwright waits until the element is ready, so most hand-written waits are not needed. Learn what it checks and what it cannot.
L1–L4 are part of the Pro pass
L0 Explain simply
Analogy: a waiter who checks the table before seating you. The waiter looks for the table, checks that it is clear, and checks that nobody is still sitting there. Only then do you sit. Sitting at once lands you on a stranger.
Daily List is a to-do list app. The Add task button slides in with a panel. For a moment the button is moving. Then a spinner covers it. A click in that moment hits the wrong spot.
What it is: Playwright is a library that drives a real browser. This slice is auto-waiting: the actionability checks Playwright repeats before it clicks or types. asks whether the element is ready for that action. The nearest neighbour is a fixed pause, such as waiting three seconds and hoping. Selenium teams often write those waits by hand. some commands too, and the checks are not identical.
Why it matters: A click on a moving or covered button fails on a slow day and passes on a fast one. Tom stops trusting the suite. Actionability checks wait for a real ready state, so a pass means the click landed.
The waiter sees the whole room. Playwright asks about the one element. It cannot know that the task list is still empty. Later lessons cover checks that keep trying for that.
(SYNTHETIC / TRAINING ONLY: Daily List and every person named here are made up.)
PLAIN WORDS · 5 in this section
- playwright
- a free Microsoft tool that drives a browser for tests
- actionability
- whether an element is ready for action, such as visible
- selenium
- A free tool that drives a web browser for checks.
- cypress
- A free tool that drives a web browser for checks.
- retries
- tries again after a failure, or those further attempts
PICTURE IT
The picture is the one the lesson above opens with. The table below shows how each part of it matches the software.
THE REAL JOB Letting a tool wait until an element is ready before it acts on it.
- Visible
- Stable
- Enabled
- Not covered
HOW THE PICTURE MAPS
| In the picture | In the software |
|---|---|
| The waiter looking at the table | The tool asking questions about the element |
| The table being there and clean | Visible and enabled |
| Nobody still sitting down or moving chairs | Stable |
| A stranger standing in front of the seat | A hit target that is not the element |
WHERE THIS PICTURE STOPS
- A waiter sees the whole room. Playwright asks only about one element.
- A waiter can see a full kitchen. Playwright cannot see that data is on its way.
- A waiter waits as long as needed. Playwright stops at a time limit and fails.
HOOK
Look before you seat.
REMEMBER IT THIS WAY
A sequence: the real steps, in order.
Before it clicks, the tool asks four short questions: here, ready, still, clear.
| In the trick | What it stands for |
|---|---|
| Here? | visible |
| Ready? | enabled |
| Still? | stable, not moving |
| Clear? | nothing covers the element at the click point |
TELL A FRIEND
A waiter who checks the table is free and not covered before sitting you down.
OFTEN MIXED UP WITH Waits and timing in automated checks. The earlier lesson says what a wait is and compares three kinds. This lesson lists the exact checks Playwright makes for you.
Sources & standards — 3 sources
- Market practice
Auto-waiting (Playwright documentation) ↗ — Microsoft (Playwright) · Reviewed 6 November 2026: Complete extracted primary article; examples inspected, not executed. See v45 source analysis for version scope and documented source ambiguities; no upstream run claimed.
Primary source opened and operative text inspected on 6 November 2026. Scope: Complete extracted primary article; examples inspected, not executed. Current live Playwright documentation reflects 1.65 where stated; explicit older examples retain their version. Source inspection is not an execution or compatibility-test claim. See the completed v45 Playwright analysis for source discrepancies and exact reading boundaries.
- Market practice
Best practices (Playwright documentation) ↗ — Microsoft (Playwright) · Avoid fixed waits; use web-first assertions that retry (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail. A second search on 2026-10-20 returned this page for its title and matched the described content; the page was still not opened (search excerpt, page not opened).
- Market practice
Timeouts (Playwright documentation) ↗ — Microsoft (Playwright) · Reviewed 6 November 2026: Complete extracted primary article; examples inspected, not executed. See v45 source analysis for version scope and documented source ambiguities; no upstream run claimed.
Primary source opened and operative text inspected on 6 November 2026. Scope: Complete extracted primary article; examples inspected, not executed. Current live Playwright documentation reflects 1.65 where stated; explicit older examples retain their version. Source inspection is not an execution or compatibility-test claim. See the completed v45 Playwright analysis for source discrepancies and exact reading boundaries.
PRACTISE AND KEEP
Sources for this topic — 3 sources
- Market practice
Auto-waiting (Playwright documentation) ↗ — Microsoft (Playwright) · Reviewed 6 November 2026: Complete extracted primary article; examples inspected, not executed. See v45 source analysis for version scope and documented source ambiguities; no upstream run claimed.
Primary source opened and operative text inspected on 6 November 2026. Scope: Complete extracted primary article; examples inspected, not executed. Current live Playwright documentation reflects 1.65 where stated; explicit older examples retain their version. Source inspection is not an execution or compatibility-test claim. See the completed v45 Playwright analysis for source discrepancies and exact reading boundaries.
- Market practice
Best practices (Playwright documentation) ↗ — Microsoft (Playwright) · Avoid fixed waits; use web-first assertions that retry (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail. A second search on 2026-10-20 returned this page for its title and matched the described content; the page was still not opened (search excerpt, page not opened).
- Market practice
Timeouts (Playwright documentation) ↗ — Microsoft (Playwright) · Reviewed 6 November 2026: Complete extracted primary article; examples inspected, not executed. See v45 source analysis for version scope and documented source ambiguities; no upstream run claimed.
Primary source opened and operative text inspected on 6 November 2026. Scope: Complete extracted primary article; examples inspected, not executed. Current live Playwright documentation reflects 1.65 where stated; explicit older examples retain their version. Source inspection is not an execution or compatibility-test claim. See the completed v45 Playwright analysis for source discrepancies and exact reading boundaries.
Deepest material on this page: L4 — Standards & sources. Where a topic stops short of implementation depth, that is a deliberate coverage decision, not an oversight — see coverage.