We have 150.000 captcha images on media/captcha/base folder. We are using Magento We know there should be a cronjob to clear unused captcha images, but I don't know how to find it, or how to find the log to detect the problem.

I have gone through this threads/posts but they are for Magento 2:

We don't have this folder structure to check our cronjob is there: vendor/magento/module-captcha/etc/crontab.xml

What can I do to solve this situation? Thanks,

  • 1
    Captcha crontab configuration available in this location magento\app\code\core\Mage\Captcha\etc\config.xml Commented Oct 24, 2019 at 14:49
  • Thanks very much my friend
    – Peanuts
    Commented Oct 24, 2019 at 15:00

1 Answer 1


media/captcha/base is getting big with usage. Magento 1 is has a setting in app/code/core/Mage/Captcha/etc/config.xml to clean the folder periodically but this only happens when the cron is setup to work properly.

You will need to add a cronjob to run the magento cron every 5 minutes.

in a linux hosted magento you would do something like this

# open cron
crontab -e 
# add relevant task
*/5 * * * * sh /home/users/mydomain/www/cron.sh >> /home/users/mydomain/www/var/log/cron.log 2>&1
# close file and save

if this not working you can clean the folder directly

# open cron
crontab -e 
# add relevant task
*/5 * * * * rm /home/users/mydomain/www/media/captcha/base/* -rf
# close file and save

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.