Blue hyperlink border around images in HTML

When you add a hyperlink to an image in HTML it will automatically display with a blue border around that image. We don’t want it because it makes our page look ugly and unprofessional.

There are a couple of ways to remove the blue hyperlink border:

Using CSS
Add the following line to your style sheet code:

img {   border-style: none;   }

Using HTML
Add the following attribute to your image HTML code:

border="0"

Your line of code should look like this :

<img src="/image.jpg" border="0" />
Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

3 Responses to “Blue hyperlink border around images in HTML”


  1. 1 Ashok Oct 27th, 2010 at 12:16 pm

    Great trick. That helps!

  2. 2 eden Feb 1st, 2011 at 6:25 am

    fantastic! just what i was looking for. thanks

  3. 3 shisu Jun 14th, 2011 at 9:57 pm

    thanks for ur little help this blue border is annoying..

    thanks a lot ..

Leave a Reply



Pages