Visual overview showing how separate site icons are used in light and dark mode.
Huntsman Dark Mode Site Icon allows you to set a separate site icon for light and dark mode.
Upload one icon for light mode using WordPress’s built-in Site Icon, and upload a separate icon for dark mode using this plugin. The appropriate icon is then displayed automatically based on the visitor’s system theme.
No code or configuration is required. If no dark mode icon is set, WordPress behaves exactly as normal.
Site Icon (WordPress)
This is the default WordPress Site Icon and is still managed by WordPress.
Dark Mode Site Icon
This icon is only used when the user’s system is in dark mode and the browser supports prefers-color-scheme.
If the Dark Mode Site Icon is not set, the plugin does nothing and WordPress behaves normally.
The plugin exposes a public REST endpoint for accessing the Dark Mode Site Icon:
/wp-json/hdmsi/v1/icons
Example response:
{
“enabled”: true,
“dark”: {
“id”: 123,
“url”: “https://example.com/icon-dark.png”
}
}
A dark-mode Web App Manifest is also available at:
/wp-json/hdmsi/v1/manifest?mode=dark