#favicon

2026-01-04

I never gave the website favicon much thought but decided to look a bit more into it now and find it funny how Can I Use website mentions that it is a "complicated topic" in their footnotes:

caniuse.com/?search=svg+favicon

#webdev #favicon #caniuse

Inautiloinautilo
2025-12-08


Adaptive SVG favicons · Favicons using the ‘prefers-color-scheme’ media query ilo.im/168quh

_____

Hacker Newsh4ckernews
2025-11-16
2025-11-06

𝗖𝗼𝗺𝗽𝗹𝗲𝘁𝗲 𝗴𝘂𝗶𝗱𝗲 𝗮𝗯𝗼𝘂𝘁 𝗳𝗮𝘃𝗶𝗰𝗼𝗻:

#Cheat sheet #Favicon #Guide

thewhale.cc/posts/complete-gui

Audrey Roy has written this cheat sheet favicon sizes/types on her GitHub account to help your website shine in society.

Audrey Roy has written this cheat sheet favicon sizes/types on her GitHub account to help your website shine in society.
Terence Eden’s Blogblog@shkspr.mobi
2025-10-28

A Self-Hosted Favicon Proxy written in PHP

shkspr.mobi/blog/2025/10/a-sel

In theory, you should be able to get the base favicon of any domain by calling /favicon.ico - but the reality is somewhat more complex than that. Plenty of sites use a wide variety of semi-standardised images which are usually only discoverable from the site's HTML.

There are several services which allow you to get favicons based on a domain. But they all have their problems.

  • Google
    • Exposes your user's to Google's tracking.
    • Relies on redirects.
  • DuckDuckGo
    • Not officially supported by DDG.
  • Favicon.is
    • No privacy policy whatsoever.
  • Icons.horse
    • Paid service.
    • Only small size icons.
  • Favicone
    • No privacy policy.
    • Only small size icons.

I want to show favicons next to specific links, but I don't want to expose my visitors to unnecessary tracking. How can I proxy these images so they are stored and served locally?

There are a few existing services. Some use Cloudflare workers or other cloud services, there are some local-first ones which are unmaintained. But nothing modern, self-hosted, and as easy to deploy as uploading a single PHP file.

So here's my attempt to make something which will preserve user privacy, be reasonably fast, and have moderately up-to-date icons, while remaining fast and efficient.

  • Table of Contents

  • Getting the domain
  • Getting the image
  • Getting the structure right
  • Preventing abuse
  • Putting it all together
  • Getting the domain

    Assuming the request comes in to https://proxy.example.com/?domain=bbc.co.uk

    PHP has a handy FILTER_VALIDATE_DOMAIN filter which will determine if the string is a domain.

    filter_var( $domain, FILTER_VALIDATE_DOMAIN, FILTER_FLAG_HOSTNAME );

    Dealing with IDNs

    Some domains contain non-ASCII characters - for example https://莎士比亚.org/ - not all favicon services support International Domain Names.

    Using the idn_to_ascii() function, it is possible to get the Punycode domain.

    $domain = idn_to_ascii("莎士比亚.org");

    Getting the image

    1. Check if the icon has previously been downloaded.
    2. Rotate randomly between a few different Favicon services.
    3. Download the icon.
    4. Save it somewhere.

    Getting the structure right

    I know from my work on OpenBenches that storing tens of thousands of files in a single directory can be problematic. So I'll store the retrieved favicon in: /tld/domain/subdomain/

    That will make it quick to see if an icon exists. I'll save the file with a filename based on the current timestamp. That will allow me to check if an icon is out of date, and will prevent people downloading the icons directly from me.

    Preventing abuse

    I don't want anyone but visitors to my site to be able to use this service. So I'll add a (weak) check to see if the request came from my domain.

    $referer = parse_url( $_SERVER["HTTP_REFERER"], PHP_URL_HOST );if ( $referer == "shkspr.mobi") {   …}

    Some browsers may not send referers for privacy reasons. So they won't see the favicons. But they probably wouldn't have seen the images loaded from a 3rd party service. So I'll serve a default image.

    Putting it all together

    You can grab the code from my personal git service.

    #favicon #HowTo #HTML #php

    Terence EdenEdent
    2025-10-28

    🆕 blog! “A Self-Hosted Favicon Proxy written in PHP”

    In theory, you should be able to get the base favicon of any domain by calling /favicon.ico - but the reality is somewhat more complex than that. Plenty of sites use a wide variety of semi-standardised images which are usually only discoverable from the site's HTML.

    There are several services which allow you to …

    👀 Read more: shkspr.mobi/blog/2025/10/a-sel

    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-27

    Фото 🇯🇵 📷
    Nikon и Canon — халтурщики

    #favicon #pixelart #nikon #canon #ricoh #sigmaPhoto

    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-26

    Легенды, зубры прошлых лет!

    #favicon #pixelart #napster #icq #netscape #skype

    NapsterSkypeNetscapeICQ
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-25

    И снова #музыка
    Многих иконок уже нет. #MTV свою сменила, не посчитав нужным сделать 16x16. Пришлось брать старую на #archiveOrg

    #favicon #pixelart #virgin

    VirginMTV
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-25
    Kayak.comTripAdvisor
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-24
    Discogsnothing hereMusicbrainzlast.fm / audioscrobbler
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-24

    Фавиконова пятница продолжается!

    #favicon #pixelart #qnx #freebsd #openwrt #perl

    FreeBSDopenWRTQNXPerl.org
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-24

    И ещё 4 семпла. К сожалению, многие популярные сайты не заморачиваются иконками 16х16. Или кладут их не в /favicon.ico, а куда-то ещё. Стыд им и позор!

    #favicon #pixelart #duckduckgo #mastodon #panic #ebay #paniccom

    panic.comeBayDuckduckgoMastodon
    ꙮ 𝄃𝄁𝄂𝄀𝄀𝄁𝄃🇫🇯🇱🇨🇱🇧liilliil@mastodon.online
    2025-10-24

    Был такой сайт #favicon2dots. Больше нет, к сожалению. Я хочу возродить. Кое-то уже получается

    Кстати, кто знает, как в #php/ #imagick работать с прозрачность в #png? А то оно её херит и вставляет белый фон

    #pixelart #google #HaikuOS #favicon #apple #CreativeProcess #creative

    HaikuPHPGoogleApple
    Christopher Kirk-Nielsenchriskirknielsen@front-end.social
    2025-09-01

    We've all used the favicon trick to distinguish local/dev from the live site, right? Here's a quick tip to tell which file @11ty should save as the favicon to the output folder, based on the environment, without modifying template files — only the passthrough: chriskirknielsen.com/blog/cond #Eleventy #favicon

    Ricky de Laveagaricky@mastodon.acm.org
    2025-07-16

    #SVG #favicon support landed in #Safari Technology Preview 26 🎆🎇🌠
    caniuse.com/link-icon-svg

    SVG favicons feature support grid on Can I use... showing Safari 18.5 lacking support now available in Safari 26.0 - Safari Technology Preview
    GripNewsGripNews
    2025-05-27

    🌘 SVG favicon 實用指南
    ➤ 突破傳統,擁抱 SVG favicon 的深色模式優勢
    css-tricks.com/svg-favicons-in
    本文探討了使用 SVG 格式的 favicon 的優勢與實作方法,尤其著重於如何支援深色模式。雖然 SVG favicon 編輯不如傳統的圖像編輯器直觀,但透過在 SVG 檔案中嵌入 CSS 樣式,可以根據瀏覽器的主題偏好切換不同的 favicon 樣式。作者分享了實用技巧,例如使用 `brightness` 和 `invert` 濾鏡來調整深色模式下的 favicon 外觀,並介紹了 RealFaviconGenerator 這款方便的線上工具,能快速生成並優化適用於多種平臺的 favicon。
    + 以前總覺得 favicon 只是小事一樁,沒想到 SVG 格式竟然能帶來這麼多的可能性,尤其是深色模式支援,讓網站的細節更完整了!
    + 文章介紹的 RealFaviconGenerator 工具真的超方便,省去了很多手動編輯的
    開發 Mode

    IB Teguh TMteguhteja
    2025-05-06

    Discover how to override Odoo default favicon custom in just minutes! Follow our easy tutorial to brand your Odoo 17/18 instance.

    teguhteja.id/override-odoo-def

    Client Info

    Server: https://mastodon.social
    Version: 2025.07
    Repository: https://github.com/cyevgeniy/lmst