---
title: "How to Set Up Cron Jobs in Magento 2"
url: "https://magecomp.com/blog/set-up-cron-jobs-in-magento-2/"
date: "2016-02-26T16:30:30+00:00"
modified: "2025-02-22T09:51:03+00:00"
author:
  name: "Dhiren Vasoya"
  url: "https://magecomp.com/"
categories:
  - "How To"
  - "Magento 2"
word_count: 192
reading_time: "1 min read"
summary: "Cron jobs in Magento used generally to serve the purpose of automating system administration and maintenance. It helps users to schedule jobs to run periodically based on date and time we have setu..."
description: "Cron jobs in Magento used generally to serve the purpose of automating system administration and maintenance. MageComp provides a complete guide to setup cro..."
keywords: "How To, Magento 2"
language: "en"
schema_type: "Article"
related_posts:
  - title: "A Comprehensive Guide to Alternate Hreflang Tags for Magento 2 Store"
    url: "https://magecomp.com/blog/guide-to-alternate-hreflang-tags-for-magento-2-store/"
  - title: "Magento 2: How to Fix Customer Name Prefix/Suffix Showing as Numbers in Address"
    url: "https://magecomp.com/blog/magento-2-fix-customer-name-prefix-suffix-showing-as-numbers-in-address/"
  - title: "Magento 2: Drop Table from Database using Data Patch Interface"
    url: "https://magecomp.com/blog/magento-2-drop-table-from-database-using-data-patch-interface/"
---

# How to Set Up Cron Jobs in Magento 2

_Published: February 26, 2016_  
_Author: Dhiren Vasoya_  

![How to Set Up Cron Jobs in Magento 2](https://magecomp.com/blog/wp-content/uploads/2016/02/How-to-Set-Up-Cron-Jobs-in-Magento-2-1024x332.webp)

Cron jobs in Magento used generally to serve the purpose of automating system administration and maintenance. It helps users to schedule jobs to run periodically based on date and time we have setup. Alike earlier Magento 1.x versions, Magento 2 requires the cron job setup to periodically run and operate some of the features like sending newsletters, creating Google, auto updation of currency, re-indexing, customer notifications and many more.

[![Hire Magento Programmer](https://magecomp.com/blog/wp-content/uploads/2025/02/Hire-Magento-Programmer-CTA-4.webp)](https://magecomp.com/services/hire-magento-programmer/)

> A Simple to use Guide for Setting up Cron Jobs in [#Magento2](https://twitter.com/hashtag/Magento2?src=hash) <https://t.co/NorR6M55WA>
>
> — MageComp (@theMageComp) [February 26, 2016](https://twitter.com/theMageComp/status/703174498904776705)

[![Magento Malware Removal](https://magecomp.com/blog/wp-content/uploads/2025/02/Magento-Malware-Removal-CTA-3.webp)](https://magecomp.com/magento-malware-removal.html)

We are presenting the code to be implemented for successful cron job setup. Here, we have set the cron job to run every 5 minutes.

```
/usr/bin/php -c /[full path of magento root]/bin/magento cron::run >/dev/null 2>&1
/usr/bin/php -c /[full path of magento root]/update/cron.php >/dev/null 2>&1
/usr/bin/php -c /[full path of magento root]/bin/magento setup:cron:run >/dev/null 2>&1
```

![Cron jobs in Magento 2](https://magecomp.com/blog/wp-content/uploads/2016/02/setup-cron-jobs-magento-2.png)

Same as above, learn to [setup cron job for Magento 1.x](https://magecomp.com/blog/how-to-setup-a-cron-job-in-cpanel-for-magento/). If you have any comments or suggestions, please feel free to let us know.

[![Magento 2 Speed & Performance Optimization Services](https://magecomp.com/blog/wp-content/uploads/2025/02/Magento-2-Speed-Performance-Optimization-Services-CTA-1.webp)](https://magecomp.com/magento-performance-optimization.html)


---

_View the original post at: [https://magecomp.com/blog/set-up-cron-jobs-in-magento-2/](https://magecomp.com/blog/set-up-cron-jobs-in-magento-2/)_  
_Served as markdown by [Third Audience](https://github.com/third-audience) v3.5.3_  
_Generated: 2026-09-22 13:54:00 UTC_  
