{
  "doc": {
    "id": "api/commands/clearalllocalstorage",
    "title": "clearAllLocalStorage | Cypress Documentation",
    "description": "Clear all localStorage data in Cypress.",
    "section": "api",
    "source_path": "/llm/markdown/api/commands/clearalllocalstorage.md",
    "version": "3cf5b86b3403f604bdf7f3e35025c3bc3865e02c",
    "updated_at": "2026-05-07T17:44:31.931Z",
    "headings": [
      {
        "id": "api/commands/clearalllocalstorage#clearalllocalstorage",
        "text": "clearAllLocalStorage",
        "level": 1
      },
      {
        "id": "api/commands/clearalllocalstorage#syntax",
        "text": "Syntax",
        "level": 2
      },
      {
        "id": "api/commands/clearalllocalstorage#usage",
        "text": "Usage",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#arguments",
        "text": "Arguments",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#yields-learn-about-subject-management",
        "text": "Yields Learn about subject management",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#rules",
        "text": "Rules",
        "level": 2
      },
      {
        "id": "api/commands/clearalllocalstorage#requirements-learn-about-chaining-commands",
        "text": "Requirements Learn about chaining commands",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#assertions-learn-about-assertions",
        "text": "Assertions Learn about assertions",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#timeouts-learn-about-timeouts",
        "text": "Timeouts Learn about timeouts",
        "level": 3
      },
      {
        "id": "api/commands/clearalllocalstorage#see-also",
        "text": "See also",
        "level": 2
      }
    ]
  },
  "chunks": [
    {
      "id": "api/commands/clearalllocalstorage#syntax",
      "doc_id": "api/commands/clearalllocalstorage",
      "heading": "Syntax",
      "heading_level": 2,
      "content_markdown": "## Syntax\n\n```\ncy.clearAllLocalStorage()cy.clearAllLocalStorage(options)\n```\n\n### Usage\n\n**Correct Usage**\n\n```\ncy.clearAllLocalStorage()\n```\n\n### Arguments\n\n**options _(Object)_**\n\nPass in an options object to change the default behavior of `cy.clearAllLocalStorage()`.\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\n### Yields [Learn about subject management](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Subject-Management)\n\n*   `cy.clearAllLocalStorage()` yields `null`.\n",
      "section": "api",
      "anchors": [
        "syntax"
      ],
      "path": "/llm/json/chunked/api/commands/clearalllocalstorage.json",
      "token_estimate": 87
    },
    {
      "id": "api/commands/clearalllocalstorage#arguments",
      "doc_id": "api/commands/clearalllocalstorage",
      "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.clearAllLocalStorage()`.\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",
      "section": "api",
      "anchors": [
        "arguments"
      ],
      "path": "/llm/json/chunked/api/commands/clearalllocalstorage.json",
      "token_estimate": 57
    },
    {
      "id": "api/commands/clearalllocalstorage#rules",
      "doc_id": "api/commands/clearalllocalstorage",
      "heading": "Rules",
      "heading_level": 2,
      "content_markdown": "## Rules\n\n### Requirements [Learn about chaining commands](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Chains-of-Commands)\n\n*   `cy.clearAllLocalStorage()` requires being chained off of `cy`.\n\n### Assertions [Learn about assertions](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Assertions)\n\n*   `cy.clearAllLocalStorage()` cannot have any assertions chained.\n\n### Timeouts [Learn about timeouts](/llm/markdown/app/core-concepts/introduction-to-cypress.md#Timeouts)\n\n*   `cy.clearAllLocalStorage()` cannot time out.\n",
      "section": "api",
      "anchors": [
        "rules"
      ],
      "path": "/llm/json/chunked/api/commands/clearalllocalstorage.json",
      "token_estimate": 51
    }
  ]
}