Dashboard Links
Introduction
Dashboard links are a powerful feature in Grafana that allow you to connect related dashboards together, creating a seamless navigation experience for users. Instead of searching for related dashboards, you can create direct links between them, making it easier to move between different views of your data.
In this guide, you'll learn how to create various types of dashboard links, understand their use cases, and implement them effectively in your Grafana environment.
Why Use Dashboard Links?
Dashboard links serve several important purposes:
- Improved Navigation: Allow users to easily navigate between related dashboards
- Context Preservation: Maintain query parameters when moving between dashboards
- Organizational Structure: Create logical groupings of related dashboards
- Workflow Optimization: Support natural progression through monitoring workflows
Types of Dashboard Links
Grafana supports three main types of dashboard links:
- Dashboard Links: Links to other dashboards
- Panel Links: Links that appear on specific panels
- Data Links: Links that are attached to specific data points
Let's explore each of these in detail.
Creating Dashboard Links
Dashboard links appear at the top of your dashboard, allowing users to navigate to other related dashboards or external resources.
Step-by-Step Guide
- Navigate to the dashboard where you want to add links
- Click the gear icon in the top right to open the dashboard settings
- Select the "Links" tab on the left
- Click "Add Dashboard Link" or "New"
- Configure your link with the following options:
Type: dashboards (for internal dashboards) or link (for external resources)
Title: A descriptive name for your link
Tooltip: Additional information shown on hover
URL: For external links, the full URL
Dashboard: For internal links, select the target dashboard
Time range: Choose whether to preserve the current time range when following the link
Variable values: Choose whether to preserve dashboard variables
Open in new tab: Choose whether to open the link in a new browser tab
- Click "Save" to add the link
- Return to your dashboard to see the new link at the top
Example: Creating a Dashboard Link to a Related Dashboard
Let's say you have a main "System Overview" dashboard and want to link to more detailed dashboards for CPU, Memory, and Disk usage.
- Go to your "System Overview" dashboard
- Open dashboard settings and select "Links"
- Click "Add Dashboard Link"
- Set Type to "dashboards"
- Set Title to "CPU Details"
- Select your CPU dashboard from the dropdown
- Enable "Include time range" to preserve the time range when navigating
- Enable "Include template variables" to preserve any variables
- Save the link
- Repeat for Memory and Disk dashboards
The result will be navigation links at the top of your dashboard:
Creating Panel Links
Panel links appear on individual panels, allowing users to navigate to related dashboards or external resources from a specific visualization.
Step-by-Step Guide
- Go to your dashboard and edit the panel where you want to add a link
- In the panel edit view, scroll down to the "Panel links" section
- Click "Add link"
- Configure your link:
Title: A descriptive name
URL: The destination URL or dashboard
Open in new tab: Choose whether to open in a new tab
- Click "Save" to add the link
- Save the dashboard
Example: Adding a Panel Link to Documentation
Imagine you have a complex metrics panel that might need explanation:
- Edit your panel
- Scroll to "Panel links"
- Click "Add link"
- Set Title to "Metrics Documentation"
- Set URL to the documentation page
- Enable "Open in new tab"
- Save the link and the dashboard
Now users can click the link icon on the panel to access related documentation directly.
Creating Data Links
Data links are particularly powerful as they allow you to create links from specific data points within a visualization to other dashboards or external systems.
Step-by-Step Guide
- Edit the panel where you want to add data links
- Go to the "Field" tab
- Expand "Data links"
- Click "Add link"
- Configure the link:
Title: A descriptive name
URL: The destination URL, can include variables like ${__value.raw} or ${__field.name}
Open in new tab: Choose whether to open in a new tab
- Save the link and the dashboard
Example: Creating a Data Link to Trace Details
For a service monitoring dashboard, you might want to link directly to trace details:
- Edit your service latency panel
- Go to the "Field" tab
- Expand "Data links"
- Click "Add link"
- Set Title to "View Traces"
- Set URL to
http://your-tracing-system/traces?service=${__series.name}&time=${__value.time}
- Enable "Open in new tab"
- Save the link and the dashboard
Now when users click on a specific data point, they'll be taken directly to the relevant traces for that service at that time.
Variables in Dashboard Links
One of the most powerful features of dashboard links is the ability to pass variables between dashboards. This allows you to maintain context when navigating between related dashboards.
Available Variables
You can use the following variables in your dashboard links:
$__dashboard
: The name of the current dashboard$__from
and$__to
: The current time range$<variable-name>
: Any dashboard variable${__value.raw}
: The raw value of a data point (for data links)${__value.time}
: The time of a data point (for data links)${__field.name}
: The field name (for data links)${__series.name}
: The series name (for data links)
Example: Passing Variables Between Dashboards
Let's say you have a dashboard with a variable called server
that filters metrics by server name:
- Create a link to another dashboard
- Set the URL to include the variable:
d/abcd1234/server-details?var-server=${server}
- Enable "Include template variables"
Now when users navigate to the linked dashboard, it will automatically filter for the same server they were viewing.
Real-World Use Cases
Monitoring Workflow
Create a hierarchical structure for your monitoring:
Each dashboard links to more detailed views, creating a natural exploration path.
Multi-Team Dashboards
Different teams can have their own dashboards but still link to related team dashboards:
- The DevOps team creates infrastructure dashboards
- The Application team creates application performance dashboards
- Each dashboard links to related dashboards from other teams
- All link back to a common organization overview dashboard
Incident Response
Create an incident response workflow:
- Alert fires and links to an overview dashboard
- The overview dashboard has links to specific systems
- System dashboards link to deep-dive analysis dashboards
- All dashboards link to a runbook or documentation
Best Practices
- Be Consistent: Use a consistent naming convention for your links
- Don't Overdo It: Too many links can be confusing – focus on the most important relationships
- Use Tooltips: Add helpful tooltips to explain where each link leads
- Preserve Context: Enable time range and variable preservation when it makes sense
- Organize Logically: Group links in a way that follows natural troubleshooting or exploration flows
- Document Links: Include a description of your link structure in documentation
- Review Regularly: Periodically review links to ensure they're still relevant and functional
Common Issues and Solutions
Links Pointing to Non-existent Dashboards
Problem: Links point to dashboards that no longer exist. Solution: Use dashboard UIDs instead of IDs in your links, and implement a regular validation process.
Variables Not Being Passed Correctly
Problem: Variables aren't being passed between dashboards. Solution: Ensure variable names match exactly between dashboards and verify "Include template variables" is enabled.
Too Many Links Cluttering the Interface
Problem: Too many links make the dashboard hard to navigate. Solution: Use dropdown links to group related links together.
Summary
Dashboard links are a powerful feature in Grafana that enhances navigation and creates a cohesive monitoring experience. By connecting related dashboards, you can build intuitive workflows that guide users through your monitoring system.
Key takeaways:
- Dashboard links appear at the top of dashboards and connect to other dashboards or external resources
- Panel links allow navigation from specific panels
- Data links enable deep linking from specific data points
- Variables can be passed between dashboards to maintain context
- Well-designed links create natural workflows for monitoring and troubleshooting
Exercises
- Create a main dashboard with links to at least three other dashboards
- Add a panel link to a specific visualization that points to documentation
- Create a data link that takes users from a specific metric to a detailed view
- Implement a hierarchical dashboard structure for a specific application or service
- Use variables in your dashboard links to maintain context between dashboards
Additional Resources
If you spot any mistakes on this website, please let me know at [email protected]. I’d greatly appreciate your feedback! :)