﻿---
title: Install Kibana from archive on Linux or macOS
description: Kibana is provided for Linux and Darwin as a .tar.gz package. These packages are the easiest formats to use when trying out Kibana. The Linux archive...
url: https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/install-kibana-from-archive-on-linux-macos
products:
  - Kibana
---

# Install Kibana from archive on Linux or macOS
Kibana is provided for Linux and Darwin as a `.tar.gz` package. These packages are the easiest formats to use when trying out Kibana.
This package contains both free and subscription features. [Start a 30-day trial](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3028/reference/elasticsearch/configuration-reference/license-settings) to try out all of the features.
The latest stable version of Kibana can be found on the [Download Kibana](https://elastic.co/downloads/kibana) page. Other versions can be found on the [Past Releases page](https://elastic.co/downloads/past-releases).
<note>
  macOS is supported for development purposes only and is not covered under the support SLA for [production-supported operating systems](https://www.elastic.co/support/matrix#kibana).
</note>


## Step 1: Download and install the archive


### Linux

The Linux archive for Kibana 9.3.2 can be downloaded and installed as follows:
<tab-set>
  <tab-item title="Latest">
    To download and install the Kibana 9.3.2 archive, enter:
    ```sh
    curl -O https://artifacts.elastic.co/downloads/kibana/kibana-9.3.2-linux-x86_64.tar.gz
    curl https://artifacts.elastic.co/downloads/kibana/kibana-9.3.2-linux-x86_64.tar.gz.sha512 | shasum -a 512 -c - 
    tar -xzf kibana-9.3.2-linux-x86_64.tar.gz
    cd kibana-9.3.2/ 
    ```
  </tab-item>

  <tab-item title="Specific version">
    Because Kibana is an Elastic Stack product, you must install the same version number as the rest of your Elastic Stack components. Replace `<SPECIFIC.VERSION.NUMBER>` with the version that's used across your entire stack. For example, you can use 9.0.0.
    For more information, refer to [Elasticsearch version](/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/install-kibana#elasticsearch-version).
    ```sh
    curl -O https://artifacts.elastic.co/downloads/kibana/kibana-<SPECIFIC.VERSION.NUMBER>-linux-x86_64.tar.gz
    curl https://artifacts.elastic.co/downloads/kibana/kibana-<SPECIFIC.VERSION.NUMBER>-linux-x86_64.tar.gz.sha512 | shasum -a 512 -c - 
    tar -xzf kibana-<SPECIFIC.VERSION.NUMBER>-linux-x86_64.tar.gz
    cd kibana-<SPECIFIC.VERSION.NUMBER>/ 
    ```
  </tab-item>
</tab-set>


### MacOS

The Darwin archive for Kibana 9.3.2 can be downloaded and installed as follows:
<tab-set>
  <tab-item title="Latest">
    To download and install the Kibana 9.3.2 archive, enter:
    ```sh
    curl -O https://artifacts.elastic.co/downloads/kibana/kibana-9.3.2-darwin-x86_64.tar.gz
    curl https://artifacts.elastic.co/downloads/kibana/kibana-9.3.2-darwin-x86_64.tar.gz.sha512 | shasum -a 512 -c - 
    tar -xzf kibana-9.3.2-darwin-x86_64.tar.gz
    cd kibana-9.3.2/ 
    ```
  </tab-item>

  <tab-item title="Specific version">
    Because Kibana is an Elastic Stack product, you must install the same version number that's used across the stack. Replace `<SPECIFIC.VERSION.NUMBER>` with the Elastic Stack version.
    For more information, refer to [Elasticsearch version](/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/install-kibana#elasticsearch-version).
    ```sh
    curl -O https://artifacts.elastic.co/downloads/kibana/kibana-<SPECIFIC.VERSION.NUMBER>-darwin-x86_64.tar.gz
    curl https://artifacts.elastic.co/downloads/kibana/kibana-<SPECIFIC.VERSION.NUMBER>-darwin-x86_64.tar.gz.sha512 | shasum -a 512 -c - 
    tar -xzf kibana-<SPECIFIC.VERSION.NUMBER>-darwin-x86_64.tar.gz
    cd kibana-<SPECIFIC.VERSION.NUMBER>/ 
    ```
  </tab-item>
</tab-set>

<admonition title="macOS Gatekeeper warnings">
  Apple’s rollout of stricter notarization requirements affected the notarization of the 9.3.2 Kibana artifacts. If macOS displays a dialog when you first run Kibana that interrupts it, you will need to take an action to allow it to run.To prevent Gatekeeper checks on the Kibana files, run the following command on the downloaded `.tar.gz` archive or the directory to which was extracted:
  ```sh
  xattr -d -r com.apple.quarantine <archive-or-directory>
  ```
  Alternatively, you can add a security override if a Gatekeeper popup appears by following the instructions in the *How to open an app that hasn’t been notarized or is from an unidentified developer* section of [Safely open apps on your Mac](https://support.apple.com/en-us/HT202491).
</admonition>


## Step 2: Start Elasticsearch and generate an enrollment token for Kibana

[Start Elasticsearch](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/maintenance/start-stop-services/start-stop-elasticsearch).
When you start your first Elasticsearch node for the first time, it automatically performs the following security setup:
- Generates [TLS certificates](#stack-security-certificates) for the [transport and HTTP layers](/elastic/docs-builder/docs/3028/deploy-manage/security/secure-cluster-communications#communication-channels)
- Applies TLS configuration settings to [`elasticsearch.yml`](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/stack-settings)
- Sets a password for the `elastic` superuser
- Creates an enrollment token to securely connect Kibana to Elasticsearch

You can then start Kibana and enter the enrollment token, which is valid for 30 minutes. This token automatically applies the security settings from your Elasticsearch cluster, authenticates to Elasticsearch with the built-in `kibana` service account, and writes the security configuration to [`kibana.yml`](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/stack-settings).
<note>
  There are [some cases](/elastic/docs-builder/docs/3028/deploy-manage/security/self-auto-setup#stack-skip-auto-configuration) where security can’t be configured automatically because the node startup process detects that the node is already part of a cluster, or that security is already configured or explicitly disabled.
</note>

If your enrollment token has expired, then you can generate a new enrollment token for Kibana with the [`elasticsearch-create-enrollment-token`](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3028/reference/elasticsearch/command-line-tools/create-enrollment-token) tool:
```sh
bin/elasticsearch-create-enrollment-token -s kibana
```


## Step 3 (Optional): Make Kibana externally accessible

The default host and port settings configure Kibana to run on localhost:5601. To change this behavior and allow remote users to connect, you need to set up Kibana to run on a routable, external IP address. You can do this by editing the settings in [`kibana.yml`](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/configure-kibana):
1. Open `kibana.yml` in a text editor.
2. Uncomment the line `#server.host: localhost` and replace the default address with `0.0.0.0`. The `0.0.0.0` setting enables Kibana to listen for connections on all available network interfaces. In a production environment, you might want to [use a different value](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3028/reference/kibana/configuration-reference/general-settings#server-host), such as a static IP address.
   ```yaml
   server.host: 0.0.0.0
   ```
3. Save your changes and close the editor.


## Step 4: Run Kibana from the command line

Kibana can be started from the command line as follows:
```sh
./bin/kibana
```

By default, Kibana runs in the foreground, prints its logs to the standard output (`stdout`), and can be stopped by pressing `Ctrl`+`C`.
If this is the first time you’re starting Kibana, this command generates a unique link in your terminal to enroll your Kibana instance with Elasticsearch.
1. In your terminal, click the generated link to open Kibana in your browser.
2. In your browser, paste the enrollment token that was generated in the terminal when you started Elasticsearch, and then click the button to connect your Kibana instance with Elasticsearch.
3. Log in to Kibana as the `elastic` user with the password that was generated when you started Elasticsearch.

<note>
  If you need to reset the password for the `elastic` user or other built-in users, run the [`elasticsearch-reset-password`](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3028/reference/elasticsearch/command-line-tools/reset-password) tool. To generate new enrollment tokens for Kibana or Elasticsearch nodes, run the [`elasticsearch-create-enrollment-token`](https://docs-v3-preview.elastic.dev/elastic/docs-builder/docs/3028/reference/elasticsearch/command-line-tools/create-enrollment-token) tool. These tools are available in the Elasticsearch `bin` directory.
</note>

<tip>
  Kibana won’t enter interactive mode if it detects existing credentials for Elasticsearch (`elasticsearch.username` and `elasticsearch.password`) or an existing URL for `elasticsearch.hosts`.In this case, you can enroll Kibana in detached mode:Run the `kibana-setup` tool and pass the generated enrollment token with the `--enrollment-token` parameter.
  ```sh
  bin/kibana-setup --enrollment-token <enrollment-token>
  ```
</tip>


## Configure Kibana using the config file

Kibana loads its configuration from the `$KIBANA_HOME/config/kibana.yml` file by default. The format of this config file is explained in [Configure Kibana](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/configure-kibana).

## Directory layout of `.tar.gz` archives

The `.tar.gz` packages are entirely self-contained. All files and directories are, by default, contained within `$KIBANA_HOME` — the directory created when unpacking the archive.
This is very convenient because you don’t have to create any directories to start using Kibana, and uninstalling Kibana is as easy as removing the `$KIBANA_HOME` directory.  However, it is advisable to change the default locations of the config and data directories so that you do not delete important data later on.

| Type    | Description                                                                                            | Default Location                           | Setting                                |
|---------|--------------------------------------------------------------------------------------------------------|--------------------------------------------|----------------------------------------|
| home    | Kibana home directory or `$KIBANA_HOME`                                                                | Directory created by unpacking the archive |                                        |
| bin     | Binary scripts including `kibana` to start the Kibana server    and `kibana-plugin` to install plugins | `$KIBANA_HOME\bin`                         |                                        |
| config  | Configuration files including `kibana.yml`                                                             | `$KIBANA_HOME\config`                      | `[KBN_PATH_CONF](configure-kibana.md)` |
| data    | The location of the data files written to disk by Kibana and its plugins                               | `$KIBANA_HOME\data`                        |                                        |
| plugins | Plugin files location. Each plugin will be contained in a subdirectory.                                | `$KIBANA_HOME\plugins`                     |                                        |


## Next steps

You now have a basic Kibana instance set up. Consider the following next steps:
- Learn how to [configure Kibana](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/configure-kibana).
- Learn how to [access Kibana](https://www.elastic.co/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/access-kibana).
- Explore [key configuration topics](/elastic/docs-builder/docs/3028/deploy-manage/deploy/self-managed/configure-kibana#additional-topics) to learn how to secure and manage Kibana.