{"id":1464,"date":"2019-02-08T10:36:00","date_gmt":"2019-02-08T10:36:00","guid":{"rendered":"https:\/\/blog.hostinger.io\/support\/2019\/02\/08\/1583465-how-to-set-up-a-cron-job-at-hostinger\/"},"modified":"2025-08-27T07:14:16","modified_gmt":"2025-08-27T07:14:16","slug":"1583465-how-to-set-up-a-cron-job-at-hostinger","status":"publish","type":"post","link":"https:\/\/www.hostinger.com\/support\/1583465-how-to-set-up-a-cron-job-at-hostinger\/","title":{"rendered":"How to Set Up a Cron Job at Hostinger"},"content":{"rendered":"<p class=\"no-margin\">A cron job is a powerful tool that automates the execution of simple, repetitive tasks on a set schedule. With cron jobs, you can easily handle various activities such as cache clearing, monitoring, and running custom scripts, among other tasks.<\/p><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">To set up a cron job, open <b><a href=\"https:\/\/hpanel.hostinger.com\/websites\" target=\"_blank\" class=\"intercom-content-link\" rel=\"noopener\">Websites<\/a> &rarr; Dashboard<\/b>,<b> <\/b>search for <b>Cron Jobs<\/b> on the sidebar and click on it:<\/p><p class=\"no-margin\">\n<\/p><div class=\"intercom-container intercom-align-center\"><img decoding=\"async\" src=\"\/support\/wp-content\/uploads\/sites\/55\/2019\/02\/88f0f553-605e-4d1b-b8f3-0c5f2e1d91ac.jpg\" alt=\"The Cron Jobs menu option\" width=\"250\"><\/div><p class=\"no-margin\">\n<\/p><div class=\"intercom-interblocks-callout\" style=\"background-color: #e3e7fa80;border-color: #334bfa33\">\n<p class=\"no-margin\">Before adding a script to a cron job, it&rsquo;s recommended to <b>test it<\/b> and ensure it works as intended&#128161;<\/p>\n<\/div><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">To create a new cron job, enter the following information:<\/p><ul>\n<li>\n<p class=\"no-margin\"><b>Type &ndash; <\/b>select <b>PHP<\/b> to run a <b>.php<\/b> file. Otherwise, select <b>Custom<\/b> if you want to execute scripts with different extensions and commands, as well as to use <a href=\"\/support\/5646919-how-to-set-up-a-cron-job-with-special-characters-at-hostinger\" target=\"_blank\" class=\"intercom-content-link\">special characters<\/a>.<br>&#8203;<\/p>\n<\/li>\n<li>\n<p class=\"no-margin\"><b>Command to Run<\/b><\/p>\n<ul>\n<li>\n<p class=\"no-margin\">For PHP cron jobs &ndash; the path to the .php file that you want to execute<\/p>\n<\/li>\n<li>\n<p class=\"no-margin\">For custom cron jobs &ndash; any command or path to the file, usually non .php<\/p>\n<p class=\"no-margin\">\n<\/p><\/li>\n<\/ul>\n<\/li>\n<li>\n<p class=\"no-margin\"><b>Schedule <\/b>&ndash; specify when exactly you want your cron job to be executed. You can choose from common options or set a schedule up manually:<\/p>\n<\/li>\n<\/ul><div class=\"intercom-container intercom-align-center\"><img decoding=\"async\" src=\"\/support\/wp-content\/uploads\/sites\/55\/2019\/02\/ba0616c3-75b8-48fc-921b-beb4c014fa85.jpg\"><\/div><p class=\"no-margin\">\n<\/p><div class=\"intercom-interblocks-callout\" style=\"background-color: #e3e7fa80;border-color: #334bfa33\">\n<p class=\"no-margin\">Cron jobs tasks schedule is based on Coordinated Universal Time (<b>UTC+0<\/b>).<\/p>\n<\/div><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">Click on <b>Save<\/b>,<b> <\/b>and your cron job will be created. It will start executing as scheduled.<\/p><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">You can find all your existing cron jobs on the same page in the <b>List of Cron Jobs<\/b> section, where you can <a href=\"\/support\/5647075-how-to-check-cron-job-s-output-at-hostinger\" target=\"_blank\" class=\"intercom-content-link\">view their output<\/a> or delete them.<\/p><p class=\"no-margin\">\n<\/p><p class=\"no-margin\"><b>Additional Resources<\/b><\/p><ul>\n<li>\n<p class=\"no-margin\"><a href=\"https:\/\/www.hostinger.com\/tutorials\/cron-job\" target=\"_blank\" class=\"intercom-content-link\">Cron job: A comprehensive guide<\/a><\/p>\n<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Configuring cron jobs for web and cloud hosting plans at Hostinger<\/p>\n","protected":false},"author":581,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"include_on_kodee":true,"footnotes":""},"categories":[229],"tags":[],"class_list":["post-1464","post","type-post","status-publish","format-standard","hentry","category-cron-jobs"],"hreflangs":[{"locale":"en-US","link":"https:\/\/www.hostinger.com\/support\/1583465-how-to-set-up-a-cron-job-at-hostinger\/","default":1},{"locale":"es-ES","link":"https:\/\/www.hostinger.com\/es\/support\/1583465-como-configurar-un-cron-job-en-hostinger\/","default":0},{"locale":"fr-FR","link":"https:\/\/www.hostinger.com\/fr\/support\/1583465-comment-mettre-en-place-une-tache-cron-chez-hostinger\/","default":0},{"locale":"id-ID","link":"https:\/\/www.hostinger.com\/id\/support\/1583465-cara-setup-cron-job-di-hostinger\/","default":0},{"locale":"pt-PT","link":"https:\/\/www.hostinger.com\/br\/support\/1583465-como-configurar-uma-tarefa-cron-cron-job-na-hostinger\/","default":0},{"locale":"uk-UA","link":"https:\/\/www.hostinger.com\/ua\/support\/1583465----cron--hostinger\/","default":0}],"include_on_kodee":true,"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1464","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/users\/581"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/comments?post=1464"}],"version-history":[{"count":1,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1464\/revisions"}],"predecessor-version":[{"id":5193,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1464\/revisions\/5193"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/media?parent=1464"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/categories?post=1464"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/tags?post=1464"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}