diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 9f8c131968c050fb18001b5dc7c5468d0ed26dae..98975f61a6c71bedb0e8c764ad6c9e6a16687829 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -50,6 +50,12 @@ pylint:
     - pylint3 --unsafe-load-any-extension=y -d all -e E,F src/caosdb/common
   allow_failure: true
 
+mypy:
+  tags: [ docker ]
+  stage: linting
+  script:
+    - mypy  src/caosdb
+  allow_failure: true
 
 # pylint tests for pycaosdb
 test:
diff --git a/unittests/docker/Dockerfile b/unittests/docker/Dockerfile
index 7fa3f75bd198724628dee48ab328829fa071a639..286d235fea5e8ae3d358d7c5a1836a692f0b53b1 100644
--- a/unittests/docker/Dockerfile
+++ b/unittests/docker/Dockerfile
@@ -7,4 +7,4 @@ RUN apt-get update && \
 ARG COMMIT="dev"
 RUN git clone -b dev https://gitlab.indiscale.com/caosdb/src/caosdb-pylib.git && \
     cd caosdb-pylib && git checkout $COMMIT && pip3 install .
-RUN pip3 install recommonmark sphinx-rtd-theme
+RUN pip3 install recommonmark sphinx-rtd-theme mypy