diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index dfb604e3da1867871f5533f1ca47b99d157df121..3e7fa3da9667b8c77e57bd7cdf885416beae6f98 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -3,6 +3,7 @@ stages:
   - install
   - test
   - build
+  - clean-stale-branches
   - deploy
   - deploy-stable
   - releases-nightly
@@ -77,9 +78,7 @@ build:
     - npm run build -- --base-href=/cassiopee/$CI_COMMIT_REF_NAME/
 
 clean-stale-branches:
-  stage:
-    - deploy
-    - deploy-stable
+  stage: clean-stale-branches
   only:
     - pushes
     - tags