Startup
- BaseX comes with a Graphical User Interface that provides tools for managing, querying and visualizing your data, and for writing sophisticated applications in XQuery.
- The standalone Command-Line Interface is ideal if you prefer working in the terminal or need to perform batch processing.
- The Database Server is suited for multi-user environments, integration with other programming languages, or when HTTP services are not required.
- The HTTP Server enables access to the REST API. With RESTXQ, you can build complex web applications, and the embedded DBA interface allows browser-based interaction with BaseX.
- BaseX can also be embedded as a Java library within your own applications for tighter integration.
BaseX has been tested on numerous platforms, including Windows (2000, XP, Vista, 7, 10, 11), Mac OS X (10.x , 11.x), Linux (SuSE xxx, Debian, Redhat, CentOS, Ubuntu) and OpenBSD (up to 7.x). It is platform-independent and runs on any system supporting Java.
Prerequisites
Hardware
BaseX is exceptionally lightweight: for small datasets and ad-hoc tasks, as little as 16MB of RAM and an older 64-bit system may be sufficient. For more demanding operations, a modern architecture is recommended. Available main memory is automatically used to cache large database instances from disk.
Software
Make sure that you have installed Version 17, or later, of the Java Runtime Environment (JRE).
If you have several versions or distributions installed, you can type java -version
on the command-line to check which Java version is currently used.
Since 2019, Oracle has been charging fees for the use of Java. If you are looking for a suitable free distribution, our recommendation is to use the JRE packages from Adoptium.
Installation
Next, get a fresh copy of BaseX from our homepage. The following distributions are available:
Core Package
The core JAR file delivers the fundamental functionality of BaseX. It includes the database engine, XQuery processor, client/server infrastructure, and graphical user interface. The file is self-contained and operates independently of external libraries.
ZIP Package
The ZIP distribution contains extra libraries for RESTXQ web applications and other advanced features, Start Scripts, and the DBA, a browser-based admin interface. The unzipped package contain the following directories:
Directory | Description |
---|---|
bin |
Start scripts (Windows, Linux). |
data |
The database directory. |
etc |
Example data: XML sample, catalog and DTD files. |
lib |
Extra libraries (Jetty, Tagsoup, …). |
lib/custom |
Directory in which additional JAR files can be placed (Saxon, ICU, SQL drivers, etc.). |
repo |
Repository for external XQuery modules (the FunctX library is included as example). |
src |
Directory for your XQuery scripts and other source data. |
webapp |
Web Application directory: home of the RESTXQ web application, REST scripts, and DBA. |
The Global Options are stored in the .basex configuration file.
When BaseX is launched using the start scripts, all JAR files located in the lib
directory and its subdirectories are automatically included in the classpath. To make the start scripts accessible system-wide, you can add the bin
directory to your PATH environment variable.
Windows Installer
The Windows distribution contains the same files as the ZIP package. It installs BaseX in the system’s program directory, creates additional start menu shortcuts, and adds BaseX to the PATH environment variable, enabling it to be launched from the command line.
Windows does not provide free digital code-signing certificates for Open Source software. Consequently, a security prompt may appear when launching the installer. To proceed, click on More Info and then select Run anyway. We assure you that all our official releases are thoroughly verified and free from malware.
Web Archive
The WAR Archive can be embedded in existing Java web servers (Jetty, Tomcat, Wildfly, GlassFish, others).
Other Distributions
Various other distributions are available from the download page, most of which contain only the core package and, optionally, scripts for starting BaseX.
Concurrent Operations
If you want to perform parallel (concurrent) read and write operations on your databases, you must use the client/server architecture or run BaseX as a web application. You can safely open a database in different JVMs (Java virtual machines) for read-only access, and you will not encounter any problems when reading from and writing to different databases. Update operations from different JVMs to the same database will be rejected or may even lead to corrupt databases.
For example, if you only read data, you can smoothtly launch several variants of BaseX in parallel (the GUI, command-line interface database clients). As soon as you update your data, you should avoid using the GUI or the standalone CLI at the same time.
More details on concurrency can be found on the Transaction Management page.
Changelog
Version 12.0- Updated: Switched to Java 17
- Updated: Switched to Java 11
- Updated: Switched to Java 8
- Updated: Switched to Java 7
- Updated: BaseXJAXRX has been replaced with BaseXHTTP