diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 446d1dbebc546d2e853a335296aeee2bd42d0db3..9a83479b3648667df8685cdba1eacd13ebcfbb2e 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -30,8 +30,10 @@ build-rust:
   script:
     - rustup toolchain install $RUST_VERSION
     - rustup override set $RUST_VERSION
+    - rustup component add rustfmt
     - rustup component add clippy
     - rustc --version
+    - cargo fmt --check
     - cargo clippy
     - cargo build
     - cargo build --release