an ultimate svg icons collection done right

Downloads in past


1,018200.8.26 years ago7 years agoMinified + gzip package size for svg-icon in KB


An ultimate svg icons collection DONE RIGHT, with over 10,000 SVG icons out of the box.



You can download as many SVG icons as you need in homepagehomepage, or download the whole collection via npm:
npm install svg-icon --save

custom element

    ├── svg-icon-element.js
    └── svg-icon-element.css

<svg-icon url="" type="si-logos-javascript"></svg-icon>


use it locally

# clone the project
git clone
# install dependencies
cd svg-icon
npm i
# startup a local server

SVG icon collections

name | id prefix | source | supported ----|----|----|---- ant-design | ant- | | yes bootstrap | bootstrap- | | yes devicons | dev- | | yes elusive-iconfont | elusive- | | yes entypo | entypo- | | yes evil-icons | evil- | | yes flag-icon | flag- | | yes flat-ui | flat- | | yes font-awesome | awesome- | | yes foundation | foundation- | | yes game-icons | game- | | yes geomicons-open | geom- | | yes icomoon-free | icomoon- | | yes ioncons | ionic- | | yes maki | maki- | | yes map-icons | map- | | yes material-design | material- | | yes metro-ui-css | metro- | | yes mfglabs-iconset | mfglabs- | | yes octicons | oct- | | yes open-iconic | open- | | yes payment-font | payment- | | yes payment-webfont | payment-web- | | yes semantic-ui | (oct-/awesome-) | | yes simple-icons | simple- | | yes subway | subway- | | yes typicons | typcn- | | yes weather-icons | weather- | | yes windows-icons | windows- | | yes zero | zero- | src/zero | yes zocial | zocial- | | yes logos(svg porn) | logos- | | yes
Need more? Please leave an issueissues or a pull requestpull-requests.

Build your own collection

  1. Install svg-icon via npm:

npm install svg-icon -g

  1. Define a collection file (JSON format, demo)

  1. Build it:

svg-icon build --source $path/to/icons.json --target $path/to/dest --name wow

Now you have a SVG sprite file and a demo page.
    ├── index.html
    └── svg-symbols.svg


How did you collect all these SVG icons?

There are basically two kinds of icon collections, ones with SVG source files, and others with only icon fonts.
  • Those with SVG source files: I simply copy the icons to the dest folder, optimise them, trim the pads around every icon, and build an SVG sprite file from them.
  • Those with icon fonts: I need to separate every icon from a combined SVG font file(locating, transforming, etc.), optimise them, trim them, and build an SVG sprite.

So the data flow is like:
Sources(SVG icons/icon fonts) ---separating/copying---> SVG icons ---optimising---> mid products(dist/svg/*) ---trimming---> final products(dist/trimmed-svg/*) ---building---> SVG sprite

Is the contributing toolchain ready for me?

Yes, and no.
The collection of 10,000+ SVG icons is mostly collected by nodejs scripts(check out these folders for details bin/, gulp and lib ). But I still have to write some code when I want to add icons from a new vendor into this project, because of the uncertainty of icon collections.
If you are familiar with nodejs and SVG, and interested in making this collection more useful, please leave a PRpull-requests. Feel free to contact me if you have any question.
Of course, the quickest way to add your favorite icons here is to leave an issueissues, and let me do the rest for you ;-).


Projects inspired svg-icon

Projects powered svg-icon

  • svgo: transforming and optimizing SVG icons would be impossible without this awesome project.
  • vinyl-fs: gulp and vinyl-fs helped me to process large amount of files without any pain.
  • phantomjs: it is the answer of lots of problems.
  • a lot more

Known issuesissues