# Graph schema

If you need to check the data model of the data currently in the database, you
can generate a **graph schema** that will show all the node types and
relationships between them.

By selecting a certain node or relationship type, Memgraph Lab will provide
information about the current number of nodes or relationships of that type, as
well as the percentage of existence of each property across the nodes and
relationships of that type.

If you're connected to a Memgraph instance running with the
[`--schema-info-enabled` configuration
flag](https://memgraph.com/docs/querying/schema#run-time-schema-tracking), you'll see the types for each
node and relationship property.

## Generate a graph schema

To generate the graph schema, navigate to the **Graph schema** tab in the
sidebar and click on the **Reload** button. Memgraph will analyze the entire
dataset and create a visual representation of the data model. This includes:
- All detected node labels and relationship types.
- The connections between different node types based on existing relationships.
- A preview of how entities are structured in your graph.

This is especially useful when you're working with new datasets or
reverse-engineering an unknown data structure.

![](https://memgraph.com/docs/pages/data-visualization/features/graph-schema/graph-schema.png)

## Inspect properties

Once the schema is generated, you can click on any node or relationship type in
the graph to inspect its details. Lab displays:
- The total number of occurrences in the database.
- A breakdown of all the properties associated with that node or relationship
  type.
- The percentage of presence of each property (i.e., how often it appears across
  all instances).

This helps you understand which properties are consistently present, which ones
might be optional or only apply in certain contexts and whether your data is
uniform or varies between entries.

![](https://memgraph.com/docs/pages/data-visualization/features/graph-schema/schema-properties.png)

### Descriptions (Memgraph & Lab 3.10+)

You can see and edit **descriptions** on node labels, relationship types, and their
properties directly within the schema view.

> **Availability:**
> - **Memgraph**: version 3.10 and above
> - **Memgraph Lab**: version 3.10 and above

This feature helps you document your data model by adding helpful notes or
clarifications to any node label, relationship type, or property. Descriptions
you add are saved and displayed to anyone viewing the schema, making
collaboration and understanding of the graph structure easier. It's a powerful
way to document your graph data model and ensure all users share the same
up-to-date understanding of your schema.

![](https://memgraph.com/docs/pages/data-visualization/features/graph-schema/schema-descriptions.png)

**Tip:** If you've added descriptions to node labels, relationship types, or
properties, you'll also see them when running regular Cypher queries and
viewing the results in the graph view—not just in the schema tab. This is
useful for providing extra context while exploring data, as the descriptions
appear directly alongside the schema elements in your query results.

![](https://memgraph.com/docs/pages/data-visualization/features/graph-schema/query-descriptions.png)
