# xarray.Dataset.reset_index

#### Dataset.reset_index(dims_or_levels, , drop=False)[[source]](https://github.com/pydata/xarray/blob/main/xarray/core/dataset.py#L4981-L5091)

Reset the specified index(es) or multi-index level(s).

This legacy method is specific to pandas (multi-)indexes and
1-dimensional “dimension” coordinates. See the more generic
[`drop_indexes()`](xarray.Dataset.drop_indexes.html.md#xarray.Dataset.drop_indexes) and [`set_xindex()`](xarray.Dataset.set_xindex.html.md#xarray.Dataset.set_xindex)
method to respectively drop and set pandas or custom indexes for
arbitrary coordinates.

* **Parameters:**
  * **dims_or_levels** (`Hashable` or `Sequence` of `Hashable`) – Name(s) of the dimension(s) and/or multi-index level(s) that will
    be reset.
  * **drop** ([`bool`](https://docs.python.org/3/builtins/functions.html#bool), *default*: [`False`](https://docs.python.org/3/builtins/constants.html#False)) – If True, remove the specified indexes and/or multi-index levels
    instead of extracting them as new coordinates (default: False).
* **Returns:**
  **obj** ([`Dataset`](xarray.Dataset.html.md#xarray.Dataset)) – Another dataset, with this dataset’s data but replaced coordinates.

#### SEE ALSO
[`Dataset.set_index`](xarray.Dataset.set_index.html.md#xarray.Dataset.set_index), [`Dataset.set_xindex`](xarray.Dataset.set_xindex.html.md#xarray.Dataset.set_xindex), [`Dataset.drop_indexes`](xarray.Dataset.drop_indexes.html.md#xarray.Dataset.drop_indexes)
