GraphML
File format for graphs
title: "GraphML" type: doc version: 1 created: 2026-02-28 author: "Wikipedia contributors" status: active scope: public tags: ["xml-markup-languages", "graph-description-languages", "xml-based_standards"] description: "File format for graphs" topic_path: "linguistics" source: "https://en.wikipedia.org/wiki/GraphML" license: "CC BY-SA 4.0" wikipedia_page_id: 0 wikipedia_revision_id: 0
::summary File format for graphs ::
::data[format=table title="Infobox file format"]
| Field | Value |
|---|---|
| name | GraphML |
| extension | |
| developer | Graph Drawing |
| released | |
| latest_release_date | |
| genre | Graph description language |
| standard | |
| url | |
| :: |
| name = GraphML
| icon =
| iconcaption =
| icon_size =
| screenshot =
| screenshot_size =
| caption =
|_noextcode =
| extension =
|_nomimecode =
| mime =
| type code =
| uniform_type =
| conforms_to =
| magic =
| developer = Graph Drawing
| released =
| latest_release_version =
| latest_release_date =
| genre = Graph description language
| container_for =
| contained_by =
| extended_from =
| extended_to =
| standard =
| free =
| url =
GraphML is an XML-based file format for graphs. The GraphML file format results from the joint effort of the graph drawing community to define a common format for exchanging graph structure data. It uses an XML-based syntax and supports the entire range of possible graph structure constellations including directed, undirected, mixed graphs, hypergraphs, and application-specific attributes.
Overview
A GraphML file consists of an XML file containing a graph element, within which is an unordered sequence of node and edge elements. Each node element should have a distinct id attribute, and each edge element has source and target attributes that identify the endpoints of an edge by having the same value as the id attributes of those endpoints.
Here is what a simple undirected graph with two nodes and one edge between them looks like:
::code[lang=xml]
::
Additional features of the GraphML language allow its users to specify whether edges are directed or undirected, and to associate additional data with vertices or edges.
References
References
- "Handbook of Graph Drawing and Visualization". CRC Press.
::callout[type=info title="Wikipedia Source"] This article was imported from Wikipedia and is available under the Creative Commons Attribution-ShareAlike 4.0 License. Content has been adapted to SurfDoc format. Original contributors can be found on the article history page. ::