Tox is a test automation tool designed to work with python projects. If you using it within your continues integration or continues deployment pipeline it makes sense to implement links checking within tox.

Next example is:

  1. Building documentation using mkdocs and -s options will abort pipeline with an error if a problem with mkdocs itself or documentation found.

  2. Run mkdocs with serve command in the background to make it available at

  3. Run deadlinks against in 10 threads and retry 3 times to get URLs, with no progress report and fail if failed URLs are found.

  4. Failed URLs will be printed to stdout.

  5. deadlinks (version 0.1.0 and above) installed from requirements_dev.txt.

basepython = python3
ignore_errors = False
whitelist_externals = sh
commands =
    ; -s abort the build on any warnings
    mkdocs build -s --clean --site-dir build/docs/html --theme readthedocs
    ; running mkdocs to serve the documentation at
    sh -c 'mkdocs serve --dev-addr --theme readthedocs 2>&1 > /dev/null &'
    ; checking links liveness
    deadlinks -n 10 -r 3 --no-progress --fiff

deps =