How to create images as links with no borders

Updated: 02/01/2021 by Computer Hope

Any image that's linked has a border around the image to help indicate it is a link with older browsers. Adding border="0" to your img tag prevents that picture from having a border around the image.

<a href="https://www.computerhope.com"><img src="https://www.computerhope.com/cdn/media/logo-200-gray.png" border="0" alt="Logo"></a>

However, adding border="0" to every image would not only be time consuming but also increase the file size and download time. To prevent all images from having a border, create a CSS (cascading style sheets) rule or file with the following code.

img { border-style: none; }

Example

Computer Hope Logo