
A Step-by-Step Guide to Duplicating Kibana Dashboards Across Spaces
Kibana is an incredibly powerful tool for data visualization, but as your organization grows, managing dashboards across different teams or environments can become a challenge. Kibana Spaces provide an excellent way to organize your dashboards, visualizations, and other saved objects, creating separate work areas for different use cases. However, you’ll often need to reuse a well-crafted dashboard in a new Space without rebuilding it from scratch.
Manually recreating a complex dashboard is not only time-consuming but also prone to error. Fortunately, there is a straightforward and efficient method for copying dashboards from one Space to another. This guide will walk you through the entire process, ensuring you can manage your Kibana environment with confidence and consistency.
Why Duplicate a Dashboard?
Before diving into the “how,” it’s helpful to understand the “why.” Duplicating dashboards is a common requirement in many scenarios:
- Environment Promotion: You may have a dashboard in a
development
Space that has been tested and is ready to be moved to aproduction
Space. - Team-Specific Customization: You can create a master dashboard template and then copy it to different team Spaces (e.g., Marketing, Engineering, Sales), allowing each team to customize it for their specific needs.
- Access Control: Different Spaces can have unique security and access permissions. Copying a dashboard allows you to make it available to a new set of users without altering the original.
The Essential Export/Import Method
The most reliable way to duplicate a dashboard between Spaces is by using Kibana’s built-in export and import functionality for saved objects. This process ensures that the dashboard and all its dependent components, like visualizations and index patterns, are transferred correctly.
Here’s how to do it, step by step:
Step 1: Export the Dashboard from the Source Space
First, you need to export the dashboard from its original location.
- Navigate to the Kibana Space that contains the dashboard you want to copy.
- Open the main menu and go to Stack Management > Kibana > Saved Objects.
- Find the dashboard you wish to duplicate. You can use the search bar and filter by the “Dashboard” type to narrow down the list.
- Select the checkbox next to the dashboard.
- Crucially, you must also export all associated objects. At the bottom of the screen, click the “Include related objects” toggle. This will automatically select all the visualizations, searches, and index patterns that the dashboard depends on. Failing to do this will result in a broken dashboard in the new Space.
- Click the Export button. Kibana will generate and download a
.ndjson
file containing all the selected objects.
Step 2: Switch to the Target Space
Now that you have the exported file, you need to move to the destination where you want the new dashboard to live.
- Click on your user profile or the Space avatar in the top-left corner of the Kibana interface.
- From the dropdown menu, select the target Space you want to import the dashboard into.
Step 3: Import the Dashboard into the New Space
You are now in the correct Space and ready to import the file.
- Once again, navigate to Stack Management > Kibana > Saved Objects.
- In the top-right corner, click the Import button.
- Drag and drop the
.ndjson
file you downloaded earlier, or click to browse and select it from your computer. - After the file is loaded, Kibana will show you a list of the objects to be imported. You may be prompted to handle conflicts if an object with the same ID already exists in the target Space. You can choose to automatically overwrite existing objects or have Kibana create new objects with different IDs. For a clean copy, creating new objects is often the safest choice.
- Click the Import button to complete the process.
Once the import is finished, you can navigate to the Dashboards section in your new Space, and you will see a perfect copy of your original dashboard, ready to use.
Best Practices for Managing Duplicated Dashboards
While the process is simple, following a few best practices can prevent confusion and enhance security in your Kibana environment.
- Establish a Naming Convention: When managing multiple versions of the same dashboard across Spaces, use clear naming conventions (e.g.,
[PROD] - Sales Performance
vs.[DEV] - Sales Performance
) to avoid ambiguity. - Verify Permissions After Import: Remember that Kibana Spaces have their own security rules. Copying a dashboard does not automatically copy its permissions. After importing, ensure you configure the appropriate Role-Based Access Control (RBAC) in the new Space to grant access to the correct users and teams.
- Use Exports for Backups: The
.ndjson
export process is also an excellent way to create manual backups of your critical dashboards and visualizations. Regularly exporting your most important work can save you from accidental deletions or modifications. - Document Your Master Dashboards: If you are using one dashboard as a “golden template,” make sure to document its location and purpose. This prevents the master version from being accidentally altered when team members are meant to be working on their own copies.
Source: https://kifarunix.com/how-to-copy-kibana-dashboard-to-another-kibana-space/