Skip to content
masterclass Buddy

Cypress · Method

cy.each

.each() runs a callback for every item in an array-like Cypress subject. It supports DOM collections, arrays, promises, per-item timeouts, and early exit.

Last updated

Syntax

.each(callbackFn)
.each(options, callbackFn)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • .spread()
  • .then()
  • .should()
  • cy.wrap()
  • cy.getCookies()

Source: each | Cypress Documentation. Checked 2026-11-03.