{
  "schema_version": 2,
  "id": "commands/hincrbyfloat",
  "title": "HINCRBYFLOAT",
  "url": "https://redis.io/docs/latest/commands/hincrbyfloat/",
  "summary": "Increments the floating point value of a field by a number. Uses 0 as initial value if the field doesn't exist.",
  "since": "2.6.0",
  "tags": [
    "docs",
    "develop",
    "stack",
    "oss",
    "rs",
    "rc",
    "oss",
    "kubernetes",
    "clients"
  ],
  "last_updated": "2026-09-18T09:47:41+01:00",
  "page_type": "content",
  "content_hash": "ddf67d48087b66b2115a0b53ca2f350dd25725bb893cfea8d51c49be0cf90b97",
  "sections": [
    {
      "id": "overview",
      "title": "Overview",
      "role": "overview",
      "text": "Increment the specified `field` of a hash stored at `key`, and representing a\nfloating point number, by the specified `increment`. If the increment value\nis negative, the result is to have the hash field value **decremented** instead of incremented.\nIf the field does not exist, it is set to `0` before performing the operation.\nAn error is returned if one of the following conditions occur:\n\n* The key contains a value of the wrong type (not a hash).\n* The current field content or the specified increment are not parsable as a\n  double precision floating point number.\n\nThe exact behavior of this command is identical to the one of the [`INCRBYFLOAT`](https://redis.io/docs/latest/commands/incrbyfloat)\ncommand, please refer to the documentation of [`INCRBYFLOAT`](https://redis.io/docs/latest/commands/incrbyfloat) for further\ninformation."
    },
    {
      "id": "required-arguments",
      "title": "Required arguments",
      "role": "content",
      "text": "<details open><summary><code>key</code></summary>\n\nThe name of the key that holds the hash.\n\n</details>\n\n<details open><summary><code>field</code></summary>\n\nThe field whose value to increment.\n\n</details>\n\n<details open><summary><code>increment</code></summary>\n\nThe floating-point amount to add to the field's value. A negative value decrements the field instead.\n\n</details>"
    },
    {
      "id": "examples",
      "title": "Examples",
      "role": "example",
      "text": "redis> HSET mykey field 10.50\n(integer) 1\nredis> HINCRBYFLOAT mykey field 0.1\n\"10.6\"\nredis> HINCRBYFLOAT mykey field -5\n\"5.6\"\nredis> HSET mykey field 5.0e3\n(integer) 0\nredis> HINCRBYFLOAT mykey field 2.0e2\n\"5200\""
    },
    {
      "id": "implementation-details",
      "title": "Implementation details",
      "role": "content",
      "text": "The command is always propagated in the replication link and the Append Only\nFile as a [`HSET`](https://redis.io/docs/latest/commands/hset) operation, so that differences in the underlying floating point\nmath implementation will not be sources of inconsistency."
    },
    {
      "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\n[Bulk string reply](../../develop/reference/protocol-spec#bulk-strings): the value of the field after the increment operation.\n\n**RESP3:**\n\n[Bulk string reply](../../develop/reference/protocol-spec#bulk-strings): The value of the field after the increment operation."
    }
  ],
  "examples": []
}
