Skip to content

Key Press

Type: page-key-press  ·  Package: Browser v1.0.0

Sends a key or combination to the page, such as Enter, Tab, Escape, F5, or shortcuts such as Control+a. Useful for confirming forms with Enter, moving between fields with Tab, closing dialogs with Escape or triggering application keyboard shortcuts.

If you indicate a selector, first focus that element and then send the key(s). If you omit it, the key is sent to the page (to the element with focus). The keys use the Playwright names (see examples), and the combinations join with +.

ParameterEditorDescription
keysexpressionKey or combination. Ex: Tab, Enter, Escape, F5, Control+a, Shift+Tab, Control+Shift+i.
ParameterEditorDescription
pagesessionThe page session. Omit it inside a body; outside, pass = page.
selectorselectorElement to focus before sending the key. If skipped, goes to page.
timeoutnumberMaximum ms to wait for the element (when there is a selector). By default 30000.
Teclakeys
Enter / IntroEnter
TabuladorTab
EscapeEscape
FlechasArrowDown, ArrowUp, ArrowLeft, ArrowRight
FuncionesF1F12
Seleccionar todoControl+a
Tab inversoShift+Tab

Search and confirm with Enter:

Page Fill selector = (#buscar) value = "factura 2026"
Page Key Press selector = (#buscar) keys = "Enter"
  • Type Text — escribir texto (no teclas especiales).
  • Click — alternative to confirm by pressing a button.