{
  "doc": {
    "id": "api/commands/title",
    "title": "cy.title()",
    "description": "Get the document.title property of the page that is currently active in Cypress.",
    "section": "api",
    "source_path": "/llm/markdown/api/commands/title.md",
    "version": "e6c8d867c21227247f14714fb5690c7c018983c5",
    "updated_at": "2026-08-08T12:39:37.868Z",
    "headings": [
      {
        "id": "api/commands/title#title",
        "text": "title",
        "level": 1
      },
      {
        "id": "api/commands/title#syntax",
        "text": "Syntax",
        "level": 2
      },
      {
        "id": "api/commands/title#usage",
        "text": "Usage",
        "level": 3
      },
      {
        "id": "api/commands/title#arguments",
        "text": "Arguments",
        "level": 3
      },
      {
        "id": "api/commands/title#yields",
        "text": "Yields",
        "level": 3
      },
      {
        "id": "api/commands/title#examples",
        "text": "Examples",
        "level": 2
      },
      {
        "id": "api/commands/title#no-args",
        "text": "No Args",
        "level": 3
      },
      {
        "id": "api/commands/title#assert-that-the-documents-title-is-my-awesome-application",
        "text": "Assert that the document's title is \"My Awesome Application\"",
        "level": 4
      },
      {
        "id": "api/commands/title#rules",
        "text": "Rules",
        "level": 2
      },
      {
        "id": "api/commands/title#requirements",
        "text": "Requirements",
        "level": 3
      },
      {
        "id": "api/commands/title#assertions",
        "text": "Assertions",
        "level": 3
      },
      {
        "id": "api/commands/title#timeouts",
        "text": "Timeouts",
        "level": 3
      },
      {
        "id": "api/commands/title#command-log",
        "text": "Command Log",
        "level": 2
      },
      {
        "id": "api/commands/title#history",
        "text": "History",
        "level": 2
      },
      {
        "id": "api/commands/title#see-also",
        "text": "See also",
        "level": 2
      }
    ]
  },
  "chunks": [
    {
      "id": "api/commands/title#syntax",
      "doc_id": "api/commands/title",
      "heading": "Syntax",
      "heading_level": 2,
      "content_markdown": "## Syntax\n\n```\ncy.title()cy.title(options)\n```\n\n### Usage\n\n**Correct Usage**\n\n```\ncy.title() // Yields the documents title as a string\n```\n\n### Arguments\n\n**options _(Object)_**\n\nPass in an options object to change the default behavior of `cy.title()`.\n\n| Option | Default | Description |\n| --- | --- | --- |\n| `log` | `true` | Displays the command in the [Command log](/llm/markdown/app/core-concepts/open-mode.md#Command-Log) |\n| `timeout` | [`defaultCommandTimeout`](/llm/markdown/app/references/configuration.md#Timeouts) | Time to wait for `cy.title()` to resolve before [timing out](#Timeouts) |\n\n### Yields\n\n*   `cy.title()` 'yields the `document.title` property of the current page.\n*   `cy.title()` is a query, and it is _safe_ to chain further commands.\n",
      "section": "api",
      "anchors": [
        "syntax"
      ],
      "path": "/llm/json/chunked/api/commands/title.json",
      "token_estimate": 139
    },
    {
      "id": "api/commands/title#arguments",
      "doc_id": "api/commands/title",
      "heading": "Arguments",
      "heading_level": 3,
      "content_markdown": "### Arguments\n\n**options _(Object)_**\n\nPass in an options object to change the default behavior of `cy.title()`.\n\n| Option | Default | Description |\n| --- | --- | --- |\n| `log` | `true` | Displays the command in the [Command log](/llm/markdown/app/core-concepts/open-mode.md#Command-Log) |\n| `timeout` | [`defaultCommandTimeout`](/llm/markdown/app/references/configuration.md#Timeouts) | Time to wait for `cy.title()` to resolve before [timing out](#Timeouts) |\n",
      "section": "api",
      "anchors": [
        "arguments"
      ],
      "path": "/llm/json/chunked/api/commands/title.json",
      "token_estimate": 79
    },
    {
      "id": "api/commands/title#rules",
      "doc_id": "api/commands/title",
      "heading": "Rules",
      "heading_level": 2,
      "content_markdown": "## Rules\n\n### Requirements\n\n*   `cy.title()` requires being chained off of `cy`.\n\n### Assertions\n\n*   `cy.title()` will automatically [retry](/llm/markdown/app/core-concepts/retry-ability.md) until all chained assertions have passed\n\n### Timeouts\n\n*   `cy.title()` can time out waiting for assertions you've added to pass.\n",
      "section": "api",
      "anchors": [
        "rules"
      ],
      "path": "/llm/json/chunked/api/commands/title.json",
      "token_estimate": 52
    },
    {
      "id": "api/commands/title#command-log",
      "doc_id": "api/commands/title",
      "heading": "Command Log",
      "heading_level": 2,
      "content_markdown": "## Command Log\n\n**_Assert that the document's title includes 'New User'_**\n\n```\ncy.title().should('include', 'New User')\n```\n\nThe commands above will display in the Command Log as:\n\nWhen clicking on `title` within the command log, the console outputs the following:\n",
      "section": "api",
      "anchors": [
        "command-log"
      ],
      "path": "/llm/json/chunked/api/commands/title.json",
      "token_estimate": 52
    }
  ]
}