Add Icons to Your External Links Purely with CSS

By admin
That HTML Blog is the fresh place to be for posts about developing websites & applications using “vanilla” & standards-adjacent web technologies. Got a rad link to feature on the blog? Send it our way!

I’ve just recently implemented custom styling for external links within posts on this site. The good news is we don’t need to append a special class to external links or alter the markup in any way. We can simply use an attribute selector.

Apparently this is

Michelle Barker

day, as we have another excellent writeup from


this time all about how to style external links and add SVG icons without any additional HTML or JavaScript needed:

Get this: a


digest of thrilling links sent right to your inbox. w00t! 🙌

The content throughout this blog is hand-curated by me,

Jared White

, and is

Copyright © 2023

. Articles excerpted and linked to are under copyright by their respective authors unless otherwise indicated.

Return to Top 🔝

To the extent I have any control over this, no “large language” machine learning model or any “AI” training dataset may include any of the content on this website.

This blog stands in solidarity with all other bloggers in the blogosphere valiantly rebuilding after the devastation wrought by

Big Social

. Long live the indie web!