Skip to main content


What is XPath?

XPath is the abbreviation for “XML Path Language”. This is a platform-independent language that can be used to describe the paths for XML documents. The “Extensible Markup Language”, abbreviated as “XML”, is a so-called markup language. It is used for representing hierarchically structured data in text form that can be read by both machines and humans. For example, XML is used on the Web to exchange data between computer systems. In order to exchange data independently of the platform and to be able to make queries to XML documents, XPath was developed by the W3 consortium and first introduced in 1999.


By loading the video, you agree to YouTube’s privacy policy.
Learn more

Load video

The Xpath Data Model

XML Path Language uses a data model similar to the Document Object Model (DOM). Individual XML elements are located by paths, similar to a Unix directory with root directory, folders and subfolders. Part of these paths are nodes and axis points.

The XML Path Language knows a total of seven different node types

  • element nodes – element nodes
  • root nodes – document nodes
  • attribute nodes – Attribute nodes
  • text nodes – text nodes
  • namespace nodes – namespace nodes
  • processing instruction nodes – processing instruction nodes
  • comment nodes – comment nodes

XPath now includes over 200 built-in functions. There are functions for strings, numeric values, Boolean values, and date and time comparison, among others. XML Path Language expressions can be used in JavaScript, C and C++, PHP, Python and other programming languages as well as in XSLT.

For more information on this topic, click here:

Do you have any more questions?

Please contact us

Further contents