CLI for generating favicons from SVG source
npm install -g @voxpelli/generate-favicon
npm install -D @voxpelli/generate-favicon
Usage
$ generate-favicon example.svg
Output options
--background [#0000] -b A background color to use when extending (parsed using "color-string")
--ico -i Whether to output a .ico file (in a standard size)
--name -n Custom name to use for output
--no-default Skips default favicon output
--size -s The size to output PNG file for with optional values using a ":" as a separator: size:name:padding:suffix
Options
--dry-run Runs without saving anything
--help Prints this help and exits.
--silent Use to silent any text output
--version Prints current version and exits.
Examples
$ generate-favicon --name something --background #000 --no-default --size 120 --size 240 --ico example.svg
$ generate-favicon --background #000 example.svg example-2.svg
- This tool is inspired and based on the excellent How to Favicon in 2025: Three files that fit most needs