cat aliases APIedit

Returns information about currently configured aliases to indices, including filter and routing information.


GET _cat/aliases/<alias>

GET _cat/aliases


  • If the Elasticsearch security features are enabled, you must have the view_index_metadata or manage index privilege for any alias you retrieve.

Path parametersedit

(Optional, string) Comma-separated list of aliases to retrieve. Supports wildcards (*). To retrieve all aliases, omit this parameter or use * or _all.

Query parametersedit

(Optional, string) Short version of the HTTP accept header. Valid values include JSON, YAML, etc.
(Optional, string) Comma-separated list of column names to display.
(Optional, Boolean) If true, the response includes help information. Defaults to false.
(Optional, Boolean) If true, the request retrieves information from the local node only. Defaults to false, which means information is retrieved from the master node.
(Optional, string) Comma-separated list of column names or column aliases used to sort the response.
(Optional, Boolean) If true, the response includes column headings. Defaults to false.

(Optional, string) Type of index that wildcard expressions can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as open,hidden. Valid values are:

Match any data stream or index, including hidden ones.
Match open, non-hidden indices. Also matches any non-hidden data stream.
Match closed, non-hidden indices. Also matches any non-hidden data stream. Data streams cannot be closed.
Match hidden data streams and hidden indices. Must be combined with open, closed, or both.
Wildcard expressions are not accepted.


GET _cat/aliases?v=true

The API returns the following response:

alias  index filter routing.index is_write_index
alias1 test1 -      -            -              -
alias2 test1 *      -            -              -
alias3 test1 -      1            1              -
alias4 test1 -      2            1,2            -

This response shows that alias2 has configured a filter, and specific routing configurations in alias3 and alias4.

If you only want to get information about specific aliases, you can specify the aliases in comma-delimited format as a URL parameter, e.g., /_cat/aliases/alias1,alias2.