# ODK Validate¶

ODK Validate is a tool that ensures an XForms XML file conforms to the XForms specification.

Validate should be used to check hand-edited XForms. It is not needed when creating forms with XLSForm or ODK Build, unless you edit those forms manually after creating them.

## Setting up Validate¶

Note

The Validate file available for download is an executable Java application. Once downloaded, it can be run directly and does not need to be installed.

Before you begin…

Make sure Java 8 is installed on your system.

2. If you wish, move Validate to your Applications directory or another suitable location.

## Using Validate¶

1. Open Validate.

2. Find your XForms *.xml file using Choose file, and Open it.

3. Review and fix any warning messages.

4. If needed, Validate Again.

### Command line¶

Validating a single form:

$java -jar {path/to/validate-jar-file} {path/to/xform.xml}  Validating multiple forms: $ java -jar {path/to/validate-jar-file} [--fail-fast] {path/to/xform1.xml} {path/to/xform2.xml} {path/to/xform3.xml}


The optional –fail-fast flag tells Validate to exit on the first error rather than validating all forms and reporting an error at the end.

Warning

This tool validates XML files against the XForms specification. It does not check every detail needed to ensure smooth operation in the ODK ecosystem. For example, Aggregate requires that forms have a unique form ID, which this tool does not check.