WP Crontrol


WP Crontrol permite visualizar e controlar o que está acontecendo no sistema WP-Cron. A partir das telas administrativas você pode:

  • Veja todos os eventos Cron juntamente com seus argumentos, recorrência, funções de callback e quando será sua próxima execução.
  • Editar, excluir e executar imediatamente qualquer evento Cron.
  • Adicionar novos eventos Cron.
  • Bulk delete cron events.
  • Adicione e remova agendamentos Cron personalizados.
  • Export cron event lists as a CSV file.

WP Crontrol is aware of timezones, will alert you to events that have no actions or that have missed their schedule, and will show you a warning message if your cron system doesn’t appear to be working (for example if your server can’t connect to itself to fire scheduled cron events).


  1. Vá até o menu Ferramentas → Eventos Cron para gerenciar os eventos Cron.
  2. Vá até o menu Configurações → Agendamentos Cron para gerenciar os agendamentos Cron.

Other Plugins

I maintain several other plugins for developers. Check them out:

  • Query Monitor is the developer tools panel for WordPress.
  • User Switching provides instant switching between user accounts in WordPress.

Imagens de tela

  • Novos eventos Cron podem ser modificados, excluídos e executados.

  • New cron events can be added

  • Novos agendamentos Cron podem ser adicionados, permitindo aos desenvolvedores de plugins mais opções quando forem agendar eventos.


Does this plugin work with PHP 8?


I get the error “There was a problem spawning a call to the WP-Cron system on your site”. How do I fix this?

You can read all about problems spwaning WP-Cron here.

Why do some cron events miss their schedule?

You can read all about cron events that miss their schedule here.

Why do some cron events reappear shortly after I delete them?

If the event is added by a plugin then the plugin most likely rescheduled the event as soon as it saw that the event was missing. Unfortunately there’s nothing that WP Crontrol can do about this – you should contact the author of the related plugin and ask for advice.

Is it safe to delete cron events?

This depends entirely on the event. You can use your favourite search engine to search for the event name in order to find out which plugin it belongs to, and then decide whether or not to delete it.

If the event shows “None” as its action then it’s usually safe to delete. Please see the other FAQs for more information about events with no action.

Why can’t I delete some cron events?

The WordPress core software uses cron events for some of its functionality and removing these events is not possible because WordPress would immediately reschedule them if you did delete them. For this reason, WP Crontrol doesn’t let you delete these persistent events from WordPress core in the first place.

What does it mean when “None” is shown for the Action of a cron event?

This means the cron event is scheduled to run at the specified time but there is no corresponding functionality that will be triggered when the event runs, therefore the event is useless.

This is often caused by plugins that don’t clean up their cron events when you deactivate them. You can use your favourite search engine to search for the event name in order to find out which plugin it belongs to, and then decide whether or not to delete it.

How do I change the next run time or the recurrence of a cron event?

You can change the time and recurrence of a cron event by clicking the “Edit” link next to the event.

How can I create a cron event that requests a URL?

From the Tools → Cron Events → Add New screen, create a PHP cron event that includes PHP that fetches the URL using the WordPress HTTP API. For example:

wp_remote_get( 'http://example.com' );

Please see the “Which users can manage PHP cron events?” FAQ for information about which users can create PHP cron events.

Why do changes that I make to some cron events not get saved?

You can read all about problems with editing cron events here.

Can I export a list of cron events?

Yes, a CSV file of the event list can be exported via the “Export” button on the cron event listing screen. This file can be opened in any spreadsheet application.

Can I see a historical log of all the cron events that ran on my site?

Not yet, but I hope to add this functionality soon.

Can I see a historical log of edits, additions, and deletions of cron events and schedules?

Yes. The excellent Simple History plugin has built-in support for logging actions performed via WP Crontrol.

Qual a utilidade de adicionar novos agendamentos Cron?

Os agendamentos Cron são usados por plugins WordPress para o agendamento de eventos para que sejam executados em intervalos regulares. Os intervalos devem ser fornecidos pelo próprio WordPress ou um plugin para que seja usado. Por exemplo, muitos plugins de backup oferecem suporte a backups periódicos. Para fazer um backup semanal, primeiramente um agendamento de Cron semanal deve ser inserido no WP Crontrol, e então um plugin de backup pode aproveitar isto como um intervalo.

How do I create a new cron event?

Existem duas etapas para obter um evento Cron funcional executado regularmente. O primeiro passo é informar o WordPress sobre o gancho. Esta é a parte para a qual o WP Crontrol foi criado. O segundo passo é chamar uma função quando o seu gancho for executado.

Passo 1: Adicionando o gancho

No painel administrativo em Ferramentas → Eventos Cron, insira os detalhes do gancho. É melhor ter um hookname em conformidade com as convenções normais de nomenclatura de variáveis de PHP. O agendamento do evento significa quantas vezes o gancho será executado. Se você não encontrar um bom intervalo, então adicione um no painel administrativo em Configurações → Agendamentos Cron.

Passo 2: Escrevendo a função

Esta parte acontece no código PHP (por exemplo, no arquivo functions.php do seu tema). Para executar seu gancho, o WordPress dispara uma ação. Por esta razão, nós precisamos dizer ao WordPress qual função será executada quando essa ação for disparada. A linha a seguir realiza isso:

add_action( 'my_hookname', 'my_function' );

O próximo passo é escrever sua função. Veja aqui um exemplo simples:

function my_function() {
    wp_mail( 'hello@example.com', 'WP Crontrol', 'WP Crontrol rocks!' );

Como eu crio um novo evento do PHP Cron?

No painel administrativo em Ferramentas → Eventos Cron, clique na aba “Adicionar evento do PHP Cron” abaixo da tabela de eventos Cron. No formulário que aparece, informe nas caixas o agendamento e o horário da próxima execução. O agendamento do evento significa quantas vezes o gancho será executado. Se você não encontrar um bom intervalo, então adicione um no painel administrativo em Configurações → Agendamentos Cron. Na área de “Código do gancho”, digite o código PHP que deve ser executado quando o evento cron for disparado. Você não precisa fornecer a tag de abertuda do PHP (<?php).

Please see the “Which users can manage PHP cron events?” FAQ for information about which users can create PHP cron events.

Which users can manage cron events and schedules?

Only users with the manage_options capability can manage cron events and schedules. By default, only Administrators have this capability.

Which users can manage PHP cron events? Is this dangerous?

Only users with the edit_files capability can manage PHP cron events. This means if a user cannot edit files on the site (eg. through the Plugin Editor or Theme Editor) then they cannot edit or add a PHP cron event. By default, only Administrators have this capability, and with Multisite enabled only Super Admins have this capability.

If file editing has been disabled via the DISALLOW_FILE_MODS or DISALLOW_FILE_EDIT configuration constants then no user will have the edit_files capability, which means editing or adding a PHP cron event will not be permitted.

Therefore, the user access level required to execute arbitrary PHP code does not change with WP Crontrol activated.

Há algum comando WP-CLI disponível?

Os comandos Cron que foram incluídos anteriormente no WP Crontrol agora fazem parte do WP-CLI (desde a versão 0.16), portanto esse plugin não fornece mais comandos WP-CLI. Veja wp help cron para obter mais informações.

Who took the photo in the plugin header image?

The photo was taken by Michael Pardo and is in the public domain.


2 de novembro de 2021
Wow, this plugin is easy to use and gets the job done. Thank you so much!
27 de outubro de 2021
I didn't need this for very long but it was super helpful in figuring out what was going wrong!
25 de julho de 2021
Thank you - Thank you - Thank you. I am in the middle of starting my own little business just to keep me busy as a semi retired person in France. While testing, The last thing you want is to scratch your head for 8hrs trying to figure and wonder why your contact forms or news-letters are not are not sending on time. (visitor onload) Fresh website not enough traffic yet, and yes why would there be its still being constructed. I am going to set a server cron but leave wordpress cron active, I now realise thanks to this share resource why.. 🙂 Andrew
12 de julho de 2021
WP Crontrol opens a view into the otherwise hidden WP Cron system, which is sometimes very helpful, especially in connection with notes in Site Health. Many thanks to the developers for sharing.
Leia todas as 105 avaliações

Colaboradores e desenvolvedores

“WP Crontrol” é um software com código aberto. As seguintes pessoas contribuíram para este plugin.


“WP Crontrol” foi traduzido para 17 localizações. Agradecemos aos tradutores por suas contribuições.

Traduzir “WP Crontrol” para o seu idioma.

Interessado no desenvolvimento?

Navegue pelo código, dê uma olhada no repositório SVN ou assine o registro de desenvolvimento via RSS.

Registro de alterações


  • Fix the PHP cron event management.
  • More “namespacing” of query variables to avoid conflicts with other cron management plugins.


  • Introduced an Export feature to the event listing screen for exporting the list of events as a CSV file.
  • Added the timezone offset to the date displayed for events that are due to run after the next DST change, for extra clarity.
  • Introduced the crontrol/filter-types and crontrol/filtered-events filters for adjusting the available event filters on the event listing screen.
  • Lots of code quality improvements (thanks, PHPStan!).


  • Support for more granular cron-related error messages in WordPress 5.7
  • Several accessibility improvements
  • Warning for events that are attached to a schedule that is too frequent
  • More clarity around events and schedules that are built in to WordPress core
  • Add a Help tab with links to the wiki and FAQs


  • Fix the adding of new cron events when DISALLOW_FILE_EDIT is true.


  • Add filters and sorting to the event listing screen. Props @yuriipavlov.
  • Replace the “Add New” tabs with a more standard “Add New” button on the cron event listing page.
  • Switch back to using browser-native controls for the date and time inputs.
  • Add an error message when trying to edit a non-existent event.
  • Introduce an informational message which appears when there are events that have missed their schedule.
  • Fire actions when cron events and schedules are added, updated, and deleted.


  • Fix an issue with the tabs in 1.8.4.


  • Add a warning message if the default timezone has been changed. More information.
  • Fixed string being passed to strtotime() function when the Now option is chosen when adding or editing an event.


  • Fix the editing of events that aren’t currently listed on the first page of results.


  • Bypass the duplicate event check when manually running an event. This allows an event to manually run even if it’s due within ten minutes or if it’s overdue.
  • Force only one event to fire when manually running a cron event.
  • Introduce polling of the events list in order to show a warning when the event listing screen is out of date.
  • Add a warning for cron schedules which are shorter than WP_CRON_LOCK_TIMEOUT.
  • Add the Site Health check event to the list of persistent core hooks.


  • Fix the bottom bulk action menu on the event listing screen.
  • Make the timezone more prominent when adding or editing a cron event.


  • Searching and pagination for cron events
  • Ability to delete all cron events with a given hook
  • More accurate response messages when managing events (in WordPress 5.1+)
  • Visual warnings for events without actions, and PHP events with syntax errors
  • Timezone-related clarifications and fixes
  • A more unified UI
  • Modernised codebase


  • Correct the PHP.net URL for the strtotime() reference.


  • Remove the date and time inputs and replace with a couple of preset options and a plain text field. Fixes #24 .
  • Ensure the schedule name is always correct when multiple schedules exist with the same interval. Add error handling. Fixes #25.
  • Re-introduce the display of the current site time.
  • Use a more appropriate HTTP response code for unauthorised request errors.


  • Remove the ability to delete a PHP cron event if the user cannot edit files.
  • Remove the Edit link for PHP cron events when the user cannot edit the event.
  • Avoid a PHP notice due to an undefined variable when adding a new cron event.


  • Fix a potential fatal error on the cron events listing screen.


  • Introduce bulk deletion of cron events. Yay!
  • Show the schedule name instead of the schedule interval next to each event.
  • Add core’s new delete_expired_transients event to the list of core events.
  • Don’t allow custom cron schedules to be deleted if they’re in use.
  • Add links between the Events and Schedules admin screens.
  • Add syntax highlighting to the PHP code editor for a PHP cron event.
  • Styling fixes for events with many arguments or long arguments.
  • Improvements to help text.
  • Remove usage of create_function().
  • Fix some translator comments, improve i18n, improve coding standards.


  • Show the hooked actions for each cron event.
  • Don’t show the Delete link for core’s built-in cron events, as they get re-populated immediately.
  • Correct the success message after adding or editing PHP cron events.
  • Correct the translations directory name.


  • Switch to requiring cron event times to be input using the site’s local timezone instead of UTC.
  • Add the ability for a PHP cron event to be given an optional display name.
  • Better UX for users who cannot edit files and therefore cannot add or edit PHP cron events.
  • Terminology and i18n improvements.


  • Improvements to the UI.
  • More error detection when testing WP-Cron functionality.
  • Improve the capability checks for single site and multisite.
  • Lots of escaping and sanitising.
  • Fix various issues with multiple events with the same hook name.
  • Removed the WP-CLI commands, as these have now been added to WP-CLI core (see wp help cron for more info)


  • Tweaks to i18n and date and args formatting
  • Properly escape the crontrol_message query var (props Julio Potier)


  • Added wp crontrol run-event and wp crontrol delete-event WP-CLI commands
  • Clarify language regarding hooks/entries/events


  • Correctly display the local time when listing cron events
  • Remove a PHP notice
  • Pass the WP-Cron spawn check through the same filter as the actual spawner


  • Added support for WP-CLI
  • Removed some PHP4 code that’s no longer relevant


  • Bug fixes for running cron events and adding cron schedules
  • Added a cron spawn test to check for errors when spawning cron
  • Various small tweaks
  • WordPress 3.4 compatibility


  • Input of PHP code for cron events
  • Non-repeating cron events
  • Handles cron events with arguments


  • Internationalization
  • Editing/deleting/execution of cron events
  • More text, status messages, etc.
  • Allow a user to enter a schedule event in a human manner
  • Looks better on WordPress 2.5


  • Fully documented the code.
  • Fixed the bug that the activate action wouldn’t be run if the plugin wasn’t in a subdirectory.
  • Now will play nicely in case any other plugins specify additional cron schedules.
  • Minor cosmetic fixes.


  • Super basic, look at what’s in WP-Cron functionality.