---
id: api/commands/title
title: title | Cypress Documentation
description: >-
  Get the `document.title` property of the page that is currently active in
  Cypress.
section: api
source_path: docs/api/commands/title.mdx
version: 7ada28c0cd90e81cf56fd3fc73de6e6d45c16de6
updated_at: '2026-05-13T21:55:41.935Z'
---
# title

Get the `document.title` property of the page that is currently active.

## Syntax

```
cy.title()cy.title(options)
```

### Usage

**Correct Usage**

```
cy.title() // Yields the documents title as a string
```

### Arguments

**options _(Object)_**

Pass in an options object to change the default behavior of `cy.title()`.

| Option | Default | Description |
| --- | --- | --- |
| `log` | `true` | Displays the command in the [Command log](/llm/markdown/app/core-concepts/open-mode.md#Command-Log) |
| `timeout` | [`defaultCommandTimeout`](/llm/markdown/app/references/configuration.md#Timeouts) | Time to wait for `cy.title()` to resolve before [timing out](#Timeouts) |

### Yields [Learn about subject management](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Subject-Management)

*   `cy.title()` 'yields the `document.title` property of the current page.
*   `cy.title()` is a query, and it is _safe_ to chain further commands.

## Examples

### No Args

#### Assert that the document's title is "My Awesome Application"

```
cy.title().should('eq', 'My Awesome Application')
```

## Rules

### Requirements [Learn about chaining commands](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Chains-of-Commands)

*   `cy.title()` requires being chained off of `cy`.

### Assertions [Learn about assertions](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Assertions)

*   `cy.title()` will automatically [retry](/llm/markdown/app/core-concepts/retry-ability.md) until all chained assertions have passed

### Timeouts [Learn about timeouts](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Timeouts)

*   `cy.title()` can time out waiting for assertions you've added to pass.

## Command Log

**_Assert that the document's title includes 'New User'_**

```
cy.title().should('include', 'New User')
```

The commands above will display in the Command Log as:

When clicking on `title` within the command log, the console outputs the following:

## History

| Version | Changes |
| --- | --- |
| [< 0.3.3](/llm/markdown/app/references/changelog.md#0-3-3) | `cy.title()` command added |

## See also

*   [`cy.document()`](/llm/markdown/api/commands/document.md)
