XML FORMAT
RDF/XML logo

RDF/XML

RDF/XML (the RDF XML Syntax) is an XML-based serialization for the Resource Description Framework (RDF), the W3C's model for describing resources as directed, labeled graphs. An RDF graph is a set of triples, each pairing a subject and object node through a predicate arc; nodes are IRIs, literals, or blank nodes. RDF/XML encodes such a graph as an XML document, giving RDF its first standardized concrete syntax and, for years, its primary interchange format on the Semantic Web.

The World Wide Web Consortium published RDF/XML as a Recommendation in 1999, revised it in the 2004 RDF suite, and issued the current RDF 1.1 edition in February 2014. The format uses a "striping" pattern of alternating node and property elements wrapped in a root rdf:RDF element. Node elements are typically rdf:Description carrying an rdf:about IRI, though a class IRI can replace Description to encode an rdf:type. Property elements name predicates and hold literal text or point to objects via rdf:resource. Many abbreviations exist: property attributes fold literals onto elements, rdf:ID and xml:base shorten IRIs, xml:lang and rdf:datatype qualify literals, rdf:nodeID names blank nodes, and rdf:parseType="Resource", "Collection", or "Literal" compress nested structures. Containers (rdf:Seq, rdf:Bag, rdf:Alt) and RDF lists are also supported. The media type is application/rdf+xml with extension .rdf.

RDF/XML remains the mandatory exchange syntax for OWL 2 (format:owl) and underpins early Semantic Web deployments such as RSS 1.0 and Dublin Core metadata. In the format-conversion landscape it is one of several interchangeable RDF serializations: leaner, more readable alternatives include format:turtle, format:n-triples, format:rdf-nquads, format:trig, format:json-ld, format:rdfa, and format:rdf-json, all encoding the same triple model. Tools such as tool:apache-jena, tool:rdflib, tool:easyrdf-converter, tool:rdf2rdf, and tool:dotnetrdf parse and emit RDF/XML and translate freely between these syntaxes.

Its strengths are standardization, wide legacy tooling, and native fit with XML pipelines (XSLT, XML Schema datatypes, namespaces). Its weaknesses are well known: the syntax is verbose and hard to hand-author or read, its many abbreviation styles mean one graph has many valid encodings, and not every legal RDF graph maps cleanly to XML (for example, predicate IRIs that are not valid XML QNames). These frictions drove the adoption of Turtle and JSON-LD, so RDF/XML is now often a compatibility target rather than a preferred authoring format.

Alternative Names: RDF/XML Syntax

File Extensions: .rdf.xml Mimetype: application/rdf+xml vRDF 1.1
FeatureRDF/XML
Multiple Graphs per Document not supported
Nodes supported
Undirected Edges not supported
Directed Edges supported
Hyperedges not supported
Mixed-directionality Edges not supported
Parallel Edges supported
Self-loops supported
Edges on Edges partial
Nested Graphs in Nodes not supported
Nested Graphs in Edges not supported
Nested Graphs in Graphs not supported
Node Labels not supported
Edge Labels supported
Attributes on Nodes supported
Attributes on Edges not supported
Attributes on Graphs not supported
Typed Edges supported

Tools(Read & Write)

Read-only Tools

Frequently Asked Questions

What is a RDF/XML file?

A RDF/XML file stores a graph — its nodes, edges and attributes — in the RDF/XML format (also: RDF/XML Syntax). See the feature table above for what it supports.

How do I open a RDF/XML file?

Open it in a graph tool that supports RDF/XML, or convert it to a format your tool reads. With GraphInOut you can convert RDF/XML to GraphML, DOT, Connected JSON and more, right in your browser.

How do I convert a RDF/XML file to another format?

Use the Convert from RDF/XML link above: upload or paste your RDF/XML file (input preset to RDF/XML), choose a target format and download the result — free, no install.