Create Admin Dashboard Widgets

You can create widgets that display to admins in the Admin Area Dashboard.

Custom Widgets

You can define a widget in any hook file (for example, in a server module, registrar module, or in a standalone hook file for widgets that do not relate to a module).

All of the widgets that WHMCS includes are open-source. You can find the default widgets in the /modules/widgets folder.

All widgets require a function that returns an array that includes a title and content. Using the same methodology as our hook system, you define the custom function to WHMCS using an AdminHomeWidgets hook call.

For sample widget code, see Admin Dashboard Widgets.

Last modified: April 30, 2024