The Simplest Way to Make Kibana and Neo4j Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

Running kibana and neo4j together lets teams search log events and map data relationships. Neo4j stores graph nodes and edges, while Kibana displays trends from an Elasticsearch index. Teams link these two tools to investigate fraud, track network threats, and inspect system dependencies. You can trace a bad request in a graph and chart its frequency over time. To do this well, you must control how data and credentials move between both systems. How data and roles flow between kibana and neo4

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

Running kibana and neo4j together lets teams search log events and map data relationships. Neo4j stores graph nodes and edges, while Kibana displays trends from an Elasticsearch index.

Teams link these two tools to investigate fraud, track network threats, and inspect system dependencies. You can trace a bad request in a graph and chart its frequency over time. To do this well, you must control how data and credentials move between both systems.

How data and roles flow between kibana and neo4j

Kibana does not read data straight from a Neo4j graph database out of the box. Instead, Kibana reads indexed documents from Elasticsearch, while Neo4j runs graph queries on its own engine. Teams connect them by syncing graph records or query logs into an Elasticsearch cluster.

You can send Neo4j audit logs and slow query logs into your log pipeline. Once Elasticsearch indexes those logs, Kibana dashboards can show database load, error rates, and login events. You can also export graph nodes and relationships as JSON documents for full-text search.

Each step in this pipeline needs its own login key and role. The sync job needs a read-only role inside Neo4j to pull graph records. On the other side, the shipper needs a write role in Elasticsearch to store those events. Users who log in to Kibana only need read roles on the final index spaces.

Common failure modes in graph and dashboard pipelines

Many teams use a single admin account to connect their graph database to their log shipper. If an attacker steals that shared key, they can read or delete the entire graph. A wide-open key also makes it hard to see which person or job ran a query.

Another common mistake is sending sensitive graph properties straight into shared search indexes. Graph nodes often hold personal data like emails, phone numbers, card numbers, or national IDs. When a pipeline copies those fields into Elasticsearch, anyone with dashboard access might see them. Data masking rewrites matched fields in results so raw values do not land in open dashboards.

End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Unlogged graph queries also create blind spots during an incident review. Engineers often connect directly to Neo4j from their laptops to fix data issues. If those direct queries skip your central log index, Kibana dashboards will miss key changes. You should route all human and service queries through a path that logs every action.

Scoping network paths and permissions for your team

Start by splitting database roles by task rather than sharing one root account. Give your data sync worker a custom Neo4j role that only reads specific node labels. Set up your Elasticsearch writer key so it can only append documents to one index.

Next, lock down the network paths between your graph cluster and your search cluster. Place both databases in private subnets that block public traffic from the internet. Allow traffic only on the exact ports needed for encrypted database and index requests.

Finally, tie every database action back to a real user identity from your login provider. When an engineer runs a graph query or views a dashboard, record their user ID. Store those access logs in a protected index so security teams can review them in Kibana. Rotate your pipeline keys on a short schedule to limit the risk of leaked secrets.

Govern statements and responses across databases and APIs

Good config and scoped roles are needed setup. They do not check single queries in flight or mask sensitive fields in returned rows. Across Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, and internal HTTP endpoints, hoop.dev runs beside each supported service as an open-source proxy, a sidecar for your database or API.

First, hoop.dev guardrails block banned queries before they run. Then hoop.dev data masking rewrites matched sensitive values in responses in memory. The audit trail records every statement and verdict per resource. Furthermore, hoop.dev holds SOC 2 Type II and is open source on GitHub.

Frequently asked questions

Can Kibana query a Neo4j database directly?

No, Kibana reads data from Elasticsearch indexes rather than directly from Neo4j. To view graph data or database logs in Kibana, you must sync them into Elasticsearch first.

How should we restrict the service account that syncs graph data?

Give the sync account a read-only role in Neo4j scoped to the needed labels and properties. In Elasticsearch, give it permission to write only to the target index.

How do we protect sensitive fields when syncing Neo4j to Elasticsearch?

Filter out sensitive properties before shipping records, or apply data masking during the query step. Masking rewrites matched fields like emails, phone numbers, card numbers, or national IDs in results.

The query runs. The emails stay hidden.