Skip to content
masterclass Buddy

Cypress · Method

cy.origin

Use cy.origin() to interact with a page on another origin during the same Cypress test. Put commands for that page in its callback and pass data through the serializable args option.

Last updated

Syntax

cy.origin(url, callbackFn)
cy.origin(url, options, callbackFn)

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

Subscribe
  • cy.visit()
  • cy.request()
  • cy.location()
  • cy.url()
  • cy.title()
  • cy.intercept()
  • cy.session()
  • cy.env()

Source: cy.origin() | Cypress API Documentation. Checked 2026-11-03.