{"id":1022,"date":"2021-10-13T15:31:42","date_gmt":"2021-10-13T15:31:42","guid":{"rendered":"https:\/\/blog.hostinger.io\/support\/2021\/10\/13\/5647075-how-to-check-the-output-of-a-cron-job-at-hostinger\/"},"modified":"2026-03-16T12:12:10","modified_gmt":"2026-03-16T12:12:10","slug":"5647075-how-to-check-the-output-of-a-cron-job-at-hostinger","status":"publish","type":"post","link":"https:\/\/www.hostinger.com\/support\/5647075-how-to-check-the-output-of-a-cron-job-at-hostinger\/","title":{"rendered":"How to Check the Output of a Cron Job at Hostinger"},"content":{"rendered":"<p class=\"no-margin\">After you <b><a href=\"\/support\/1583465-how-to-set-up-a-cron-job-at-hostinger\" target=\"_blank\" class=\"intercom-content-link\">set up a Cron Job in hPanel<\/a><\/b>, you will see it in the <b>List of Cron Jobs<\/b> section. To view the result, wait for the Cron Job to be executed (based on the schedule which you set) and click on <b>View Output<\/b>: <\/p><p class=\"no-margin\">\n<\/p><div class=\"intercom-container\"><img decoding=\"async\" src=\"\/support\/wp-content\/uploads\/sites\/55\/2021\/10\/9b815a21-5489-4e61-8abe-f0a1704cc014.jpg\"><\/div><p class=\"no-margin\">\n<\/p><h2 id=\"h_6abb09bb6b\">What to Do if the Output is Empty? <\/h2><p class=\"no-margin\">If your Job&rsquo;s output is empty, most likely, the command you run doesn&rsquo;t imply an output: <\/p><p class=\"no-margin\">\n<\/p><div class=\"intercom-container intercom-align-center\"><img decoding=\"async\" src=\"\/support\/wp-content\/uploads\/sites\/55\/2021\/10\/774c2627-836e-4033-9b04-fa95ac27e028.jpg\"><\/div><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">For example, the line <code>&gt;\/dev\/null 2&gt;&amp;1<\/code> in the Cron Job is meant exactly for hiding output, and if you remove it, you&rsquo;ll see the output normally. <\/p><p class=\"no-margin\">\n<\/p><p class=\"no-margin\">As one of the solutions, you can add a task to send a simple text phrase when the cron job is executed, e.g., by adding these lines to your PHP script:<\/p><pre><code>&lt;?php<br>echo \"hello worldn\";<br>\/\/ ...<br>?&gt;<\/code><\/pre><p class=\"no-margin\">The result will look like this: <\/p><p class=\"no-margin\">\n<\/p><div class=\"intercom-container intercom-align-center\"><img decoding=\"async\" src=\"\/support\/wp-content\/uploads\/sites\/55\/2021\/10\/37118a59-69a1-4632-8ef6-f67b19d0bc79.jpg\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Viewing output of your Cron Job in hPanel<\/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-1022","post","type-post","status-publish","format-standard","hentry","category-cron-jobs"],"hreflangs":[{"locale":"en-US","link":"https:\/\/www.hostinger.com\/support\/5647075-how-to-check-the-output-of-a-cron-job-at-hostinger\/","default":1},{"locale":"es-ES","link":"https:\/\/www.hostinger.com\/es\/support\/5647075-como-verificar-la-salida-de-cron-job-en-hostinger\/","default":0},{"locale":"fr-FR","link":"https:\/\/www.hostinger.com\/fr\/support\/5647075-comment-verifier-la-sortie-de-la-tache-cron-chez-hostinger\/","default":0},{"locale":"id-ID","link":"https:\/\/www.hostinger.com\/id\/support\/5647075-bagaimana-cara-cek-output-cron-job-di-hostinger\/","default":0},{"locale":"pt-PT","link":"https:\/\/www.hostinger.com\/br\/support\/5647075-como-posso-ver-a-saida-de-uma-cron-job-no-hostinger\/","default":0},{"locale":"uk-UA","link":"https:\/\/www.hostinger.com\/ua\/support\/5647075-----\/","default":0}],"include_on_kodee":true,"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1022","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=1022"}],"version-history":[{"count":1,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1022\/revisions"}],"predecessor-version":[{"id":4138,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/posts\/1022\/revisions\/4138"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/media?parent=1022"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/categories?post=1022"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/support\/wp-json\/wp\/v2\/tags?post=1022"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}