After completing the installation procedures, you can use the available or prebuilt tagterm executable alone or under the Java wrapper found under the src directory. Check src/ as an example of handling the src/tagterm Java package.


On Windows, make sure that you have added your paths of interest properly under the PATH system environment variable or just use python tagterm under bin instead of tagterm when executing it as Python code. It is recommended to use the prebuilt executable called tagterm.exe.

# List of available commands.
tagterm --help

# Validate and convert HTML file to XHTML with permissive level 1.
tagterm -v validate -i res/error.html -p
tagterm -v convert -i res/error.html -p
# Check and watch out for nonzero exit codes.
tail tagterm.log

# Now remove tags from the XHTML file.
tagterm -v remove -i res/error-convert.xhtml
cat res/error-convert-remove.xml    # everything ok


The -v flag stands for verbose and you can also use -o option for putting the output in a separate path. Run with -h for more info, based on the chosen command.


As you can see in src/ example you can simple validate a HTML file by running this (after importing the tagterm package):

Tagterm tagterm = new Tagterm("tagterm");

For conversion, removal and their [s]tring relatives, please consult the API.


For editing the tags configuration file, you have to edit the etc/tagterm/tags file accordingly, then loading the new settings into your previously setup installed package to make a new build based on new settings.

  1. Edit tags file.
  2. Run ./ or setup.bat again.
  3. Build again.
  4. Use the newly created bin/dist/tagterm executable.