HTML5 and CSS3 Social Media Icons Without Images
As a web developer you’re always looking for ways to innovate and do things in a more efficient manner as new technologies emerge and browsers become more sophisticated. One of the ways that web developers are attempting to innovate more is by using CSS, SVG, embedded icon fonts and a number of other techniques to configure layouts and handle the visual look and feel for websites without relying on the use of images (as they would have had to in the past).
There are many benefits to this. For one, the greater number of images you use, the greater number of HTTP requests you are going to have to make. As a result your page is going to inevitably load slower due to the greater number of requests. However if you can achieve the same effect (or a similar effect) visually without the use of images (or, at the very least, fewer images) through the use of CSS3 gradients, icon fonts, SVG graphics (drawing shapes in the browser using XML) or other techniques, then the quicker load time will be a better user experience for your users. There’s also an SEO benefit to this because Google even takes page load times into account as one of it’s considerations when ranking web pages. So it’s in your best interest to have as fast a page load time as possible.
On top of this, with the emergence of Retina display on the iPhone, iPad and other devices, the whole process of serving up images now has/had another consideration thrown into the mix. If your device supports Retina display, you’d want to serve up the larger 2X sized retina images. If it does not, for efficiency’s sake, you’d want to server up the smaller images. This means 1) detecting in your website’s code whether or not the client is using a retina-display device and 2) figuring out how to properly serve up those images based on that condition. There are some really good tutorials on various techniques on how to handle this out there, but you still have to put the effort in.
Or wouldn’t it be nice to use one of the the above mentioned technologies and have retina stuff all taken care of due to the fact that visual components are essentially being drawn in the browser? Here again, there can be tremendous benefits to having to rely on images.
More could definitely be said about the subject, but one place where it may be of great benefit to leave the use of images behind is when it comes to displaying social media icons on your website. Just about every website out there has some sort of social media
Recently I’ve stumbled across a tool that is a great solution for creating icon based fonts and in this post specifically we’re gonna be talking about creating social media icons without the use of images by using an embedded webfont. These icons will render well in all modern browsers all the way back to IE8. IE7 not so much (but for that if you really wanted to you could use an image fallback). The result will be something like the following…
![]()
But it’s easy to make these different depending on how you style the CSS. That’s what’s great about not having to rely on images. The changes can be made in code, not in Photoshop!
CSS, social media






