﻿---
title: Background search and search sessions settings in Kibana
description: 
url: https://www.elastic.co/elastic/docs-builder/docs/3175/reference/kibana/configuration-reference/search-sessions-settings
products:
  - Kibana
applies_to:
  - Elastic Cloud Serverless: Unavailable
  - Elastic Stack: Preview since 9.2
---

# Background search and search sessions settings in Kibana
<important>
  **Background search replaces Search sessions.** [Background search](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3175/explore-analyze/discover/background-search) is a feature introduced in version 9.2. It replaces the **Search sessions** feature, deprecated in version 8.15.
</important>


## Background search settings
<definitions>
  <definition term="data.search.sessions.enabled">
    <stack-availability>Elastic Stack: Generally available since 9.2</stack-availability>
    <supported-on>Elastic Cloud Hosted: Generally available, Self-managed Elastic deployments: Generally available</supported-on>

`false` by default. Set to `true` to enable background searches.
Datatype: `bool`
Default: `false`
  </definition>
  <definition term="data.search.sessions.maxUpdateRetries">
    <stack-availability>Elastic Stack: Generally available since 9.2</stack-availability>
    <supported-on>Elastic Cloud Hosted: Generally available, Self-managed Elastic deployments: Generally available</supported-on>

How many retries Kibana can perform while attempting to send a search to the background. The default is `10`.
Datatype: `int`
Default: `10`
  </definition>
  <definition term="data.search.sessions.defaultExpiration">
    <stack-availability>Elastic Stack: Generally available since 9.2</stack-availability>
    <supported-on>Elastic Cloud Hosted: Generally available, Self-managed Elastic deployments: Generally available</supported-on>

How long background search results are stored before they expire and are deleted. When users extend the validity period of the background search, this setting also determines by how long. The default is `7d`.
Datatype: `string`
Default: `7d`
  </definition>
</definitions>

## Search sessions settings (deprecated)
<definitions>
  <definition term="data.search.sessions.enabled">
    <stack-availability>Elastic Stack: Deprecated since 8.15</stack-availability>
    <supported-on>Elastic Cloud Hosted: Deprecated, Self-managed Elastic deployments: Deprecated</supported-on>

Deprecated in 8.15.0. `false` by default. Set to `true` to enable search sessions.
Datatype: `bool`
Default: `false`

<admonition title="Deprecation details">
  Deprecated in 8.15.0. Replaced by the background search feature in 9.2.
</admonition>

  </definition>
  <definition term="data.search.sessions.notTouchedTimeout">
    <stack-availability>Elastic Stack: Removed in 9.2, Elastic Stack: Deprecated from 8.15 to 9.1</stack-availability>
    <supported-on>Elastic Cloud Hosted: Deprecated, Self-managed Elastic deployments: Deprecated</supported-on>

Deprecated in 8.15.0. How long Kibana stores search results from unsaved sessions, after the last search in the session completes. The default is `5m`.
Datatype: `string`
Default: `5m`

<admonition title="Deprecation details">
  Deprecated in 8.15.0. This setting was part of the search sessions feature, which has been replaced by background search in 9.2.
</admonition>

  </definition>
  <definition term="data.search.sessions.maxUpdateRetries">
    <stack-availability>Elastic Stack: Deprecated since 8.15</stack-availability>
    <supported-on>Elastic Cloud Hosted: Deprecated, Self-managed Elastic deployments: Deprecated</supported-on>

Deprecated in 8.15.0. How many retries Kibana can perform while attempting to save a search session. The default is `10`.
Datatype: `int`
Default: `10`

<admonition title="Deprecation details">
  Deprecated in 8.15.0. Replaced by the background search feature in 9.2.
</admonition>

  </definition>
  <definition term="data.search.sessions.defaultExpiration">
    <stack-availability>Elastic Stack: Deprecated since 8.15</stack-availability>
    <supported-on>Elastic Cloud Hosted: Deprecated, Self-managed Elastic deployments: Deprecated</supported-on>

Deprecated in 8.15.0. How long search session results are stored before they are deleted. Extending a search session resets the expiration by the same value. The default is `7d`.
Datatype: `string`
Default: `7d`

<admonition title="Deprecation details">
  Deprecated in 8.15.0. Replaced by the background search feature in 9.2.
</admonition>

  </definition>
</definitions>