# xarray.Index.equals

#### Index.equals(other, \*\*kwargs)[[source]](https://github.com/pydata/xarray/blob/main/xarray/core/indexes.py#L365-L391)

Compare this index with another index of the same type.

Implementation is optional but required in order to support alignment.

* **Parameters:**
  * **other** ([`Index`](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Index.html#pandas.Index)) – The other Index object to compare with this object.
  * **exclude** ([`frozenset`](https://docs.python.org/3/builtins/stdtypes.html#frozenset) of [hashable](../user-guide/terminology.html.md#term-name), *optional*) – Dimensions excluded from checking. It is None by default, (i.e.,
    when this method is not called in the context of alignment). For a
    n-dimensional index this option allows an Index to optionally ignore
    any dimension in `exclude` when comparing `self` with `other`.
    For a 1-dimensional index this kwarg can be safely ignored, as this
    method is not called when all of the index’s dimensions are also
    excluded from alignment (note: the index’s dimensions correspond to
    the union of the dimensions of all coordinate variables associated
    with this index).
* **Returns:**
  **is_equal** ([`bool`](https://docs.python.org/3/builtins/functions.html#bool)) – `True` if the indexes are equal, `False` otherwise.
