> ## Documentation Index
> Fetch the complete documentation index at: https://algolia.com/llms.txt
> Use this file to discover all available pages before exploring further.

# StateResults

> Provides the current search state and results to components.

<div className="not-prose algolia-flavor-switcher">
  <div className="afs-dropdown">
    <div className="afs-trigger" role="button" tabIndex="0" aria-haspopup="listbox">
      <span className="afs-current">React</span>

      <svg className="afs-chevron lucide lucide-chevron-down" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" aria-hidden="true">
        <path d="m6 9 6 6 6-6" />
      </svg>
    </div>

    <ul className="afs-menu" role="listbox">
      <li role="option" aria-selected="true"><a className="afs-option is-current" href="/doc/api-reference/widgets/state-results/react"><span className="afs-option-name">React</span><span className="afs-option-lib">React InstantSearch</span></a></li>
      <li role="option" aria-selected="false"><a className="afs-option" href="/doc/api-reference/widgets/state-results/vue"><span className="afs-option-name">Vue</span><span className="afs-option-lib">Vue InstantSearch</span></a></li>
    </ul>
  </div>
</div>

<Note>
  This is the React InstantSearch v7 documentation. React InstantSearch v7 is the latest version of React InstantSearch and the stable version of React InstantSearch Hooks.

  If you were using React InstantSearch v6, you can [upgrade to v7](/doc/guides/building-search-ui/upgrade-guides/react#migrate-from-react-instantsearch-v6-to-react-instantsearch-v7).

  If you were using React InstantSearch Hooks, you can still use the React InstantSearch v7 documentation, but you should check the [upgrade guide](/doc/guides/building-search-ui/upgrade-guides/react#migrate-from-react-instantsearch-hooks-to-react-instantsearch-v7) for necessary changes.

  If you want to keep using React InstantSearch v6, you can find the [archived documentation](https://www.algolia.com/old-docs/deprecated/instantsearch/react/v6/api-reference/instantsearch/).
</Note>

## About this widget

To reach the search state, results, or other metadata in React InstantSearch, you can use the [`useInstantsearch`](/doc/api-reference/widgets/use-instantsearch/react) hook.
This covers the same use cases as the `stateResults` widget used to.
