For the Cassiopeia template, Joomla will look for the favicons in the following locations:
- media/templates/site/cassiopeia/images – they are not there so Joomla will look in the next location.
- media/system/images – they are there so Joomla will use them from there.
wget -O - https://sharlines.com | grep -i favicon
<link href="/media/system/images/joomla-favicon.svg" rel="icon" type="image/svg+xml">
<link href="/media/templates/site/cassiopeia/images/favicon.ico" rel="alternate icon" type="image/vnd.microsoft.icon">
<link href="/media/system/images/joomla-favicon-pinned.svg" rel="mask-icon" color="#000">
PHP source code:
// Browsers support SVG favicons
$this->addHeadLink(HTMLHelper::_('image', 'joomla-favicon.svg', '', [], true, 1), 'icon', 'rel', ['type' => 'image/svg+xml']);
$this->addHeadLink(HTMLHelper::_('image', 'favicon.ico', '', [], true, 1), 'alternate icon', 'rel', ['type' => 'image/vnd.microsoft.icon']);
$this->addHeadLink(HTMLHelper::_('image', 'joomla-favicon-pinned.svg', '', [], true, 1), 'mask-icon', 'rel', ['color' => '#000']);
The Joomla! Favicons
https://docs-next.joomla.org/docs/templates/favicons/
What is the right way to change favicon.ico in Cassiopeia template?
https://forum.joomla.org/viewtopic.php?f=834&t=1014569&p=3739455#p3739455