{
  "schema_version": 2,
  "id": "commands/object-freq",
  "title": "OBJECT FREQ",
  "url": "https://redis.io/docs/latest/commands/object-freq/",
  "summary": "Returns the logarithmic access frequency counter of a Redis object.",
  "since": "4.0.0",
  "tags": [
    "docs",
    "develop",
    "stack",
    "oss",
    "rs",
    "rc",
    "oss",
    "kubernetes",
    "clients"
  ],
  "last_updated": "2026-06-15T06:26:34-07:00",
  "page_type": "content",
  "content_hash": "fbb42d85578b19aab692ce5a7d006091818e1af8cbd30c6a8327035bd9894737",
  "sections": [
    {
      "id": "overview",
      "title": "Overview",
      "role": "overview",
      "text": "This command returns the logarithmic access frequency counter of a Redis object stored at `key`.\n\nThe command is only available when the `maxmemory-policy` configuration directive is set to one of the LFU policies."
    },
    {
      "id": "required-arguments",
      "title": "Required arguments",
      "role": "content",
      "text": "<details open><summary><code>key</code></summary>\n\nThe name of the key.\n\n</details>"
    },
    {
      "id": "redis-software-and-redis-cloud-compatibility",
      "title": "Redis Software and Redis Cloud compatibility",
      "role": "content",
      "text": "| Redis<br />Software | Redis<br />Cloud | <span style=\"min-width: 9em; display: table-cell\">Notes</span> |\n|:----------------------|:-----------------|:------|\n| <span title=\"Supported\">&#x2705; Standard</span><br /><span title=\"Supported\"><nobr>&#x2705; Active-Active</nobr></span> | <span title=\"Supported\">&#x2705; Standard</span><br /><span title=\"Supported\"><nobr>&#x2705; Active-Active</nobr></span> |  |"
    },
    {
      "id": "return-information",
      "title": "Return information",
      "role": "returns",
      "text": "**RESP2:**\n\nOne of the following:\n[Integer reply](../../develop/reference/protocol-spec#integers): the counter's value.\n[Nil reply](../../develop/reference/protocol-spec#bulk-strings): if _key_ doesn't exist.\n\n**RESP3:**\n\nOne of the following:\n[Integer reply](../../develop/reference/protocol-spec#integers): the counter's value.\n[Null reply](../../develop/reference/protocol-spec#nulls): if _key_ doesn't exist."
    }
  ],
  "examples": []
}
