diff --git a/mixins.yml b/mixins.yml
index c7e7b78878c619f25d4c2865b009dc6106a4a19c..890a36186560feca8f0ffe9c414b7e6081470c07 100644
--- a/mixins.yml
+++ b/mixins.yml
@@ -27,6 +27,8 @@ stages:
 
 .preparecomposerplugins:
   before_script:
+    # Downgrade composer if required
+    - if [[ -n $DOWNGRADE_COMPOSER ]]; then composer self-update --$DOWNGRADE_COMPOSER; fi
     # Add the Drupal Vendor Hardening Composer Plugin.
     # see https://github.com/drupal/core-vendor-hardening
     - composer config --no-plugins --no-interaction allow-plugins.drupal/core-vendor-hardening true