Guide
Diagnosing Kibana Lens Visualization Rendering Failures in Elastic Stack 8.x
Learn how to identify why a Lens visualization shows blank or 'No data to display' and follow ordered checks to resolve index pattern, permission, or saved object issues.
Published by Tasadduq Burney
19 Jul 2025, 04:22 UTC
3 min49.5K views0

Recognizable Condition
When opening a Lens visualization in Kibana you see a blank canvas or the message “No data to display” even though the underlying index contains recent documents.
Cause/Diagnostic Table
| Possible Cause | Typical Indicator | Quick Check |
|---|---|---|
| Index pattern mismatch or deletion | Lens cannot find the pattern; error may appear in browser console as “Index pattern not found”. | Go to Stack Management → Index Patterns and verify the pattern exists and matches the one used in the visualization. |
| Insufficient user role permissions | Requests to Elasticsearch return 403 Forbidden; Lens shows no data. | Check the user’s assigned role in Security → Roles and confirm it includes read access on the indices tied to the pattern. |
| Corrupted Lens saved object JSON | Visualization fails to load; Kibana logs may contain “Failed to parse saved object”. | Inspect the saved object via Dev Tools: GET .kibana/_doc/ and validate the JSON structure. |
Ordered Checks
- Confirm the visualization ID: open the Lens visualization, copy the ID from the URL (e.g.,
visualization:id) or from the saved object list. - Verify the index pattern:
- Navigate to Stack Management → Index Patterns.
- Search for the pattern used by the visualization (you can see it in the Lens data tab).
- If the pattern is missing or renamed, note the exact name.
- Check user permissions:
- Go to Security → Roles and locate the role assigned to the user (e.g.,
kibana_user). - Ensure the role includes
readprivileges on the indices that match the pattern (e.g.,logs-*). - If the role is missing, add the appropriate index privileges.
- Go to Security → Roles and locate the role assigned to the user (e.g.,
- Inspect the Lens saved object:
- Open Dev Tools and run:
GET .kibana/_doc/ - Look for the
visStateanduiStatefields. If the JSON is malformed (e.g., missing braces, extra commas) the object is corrupted. - If you suspect corruption, do not edit the object directly unless you understand the Lens schema; instead consider recreating the visualization.
Fixes Tied to Findings
- Index pattern mismatch:
- If the pattern was deleted, recreate it with the same name and appropriate time field.
- If the pattern was renamed, update the visualization: open the Lens editor, go to the data source, and select the correct pattern.
- Insufficient permissions:
- Edit the user’s role (or assign a new role) to include
readon the target indices. - Apply the principle of least privilege: grant access only to the indices needed for the Lens visualization.
- Edit the user’s role (or assign a new role) to include
- Corrupted saved object:
- Do not manually edit the JSON unless you are familiar with the Lens saved‑object schema.
- Instead, export the visualization (if possible) or recreate it from scratch using the same index pattern and fields.
- If you must edit, make a backup of the object first and validate the JSON with a JSON linter before saving.
Escalation Criteria
- The index pattern exists and the user has correct read privileges, yet the visualization still shows no data.
- The saved object JSON appears valid but Lens fails to render with console errors such as “Cannot read property ‘length’ of undefined”.
- Repeated 403 or 500 responses from Elasticsearch when Lens queries the indices, despite role checks.
In these cases, collect the following before contacting Elastic Support:
- Kibana logs (especially
kibana.log) around the time of the failure. - Elasticsearch audit logs showing the failed requests.
- The full saved object JSON (
GET .kibana/_doc/). - Browser console output (network tab) showing the Lens request and response.
0 replies
A thoughtful contribution can make all the difference. Be the first to share one.