HTML Code For Images


Learn HTML code for images or image tutorial.


<!DOCTYPE html>
<html>
<body>

<img src="#" alt="Your Image Text" width="150" height="150">

</body>
</html>

HTML Code Displays


Your Image Text

Replacing '#' with your image path link.



Images on Another Server/Website

To point to an image on another server, you must specify an absolute (full) URL in the src attribute:


<!DOCTYPE html>
<html>
<body>

<img src="https://www.anothersite.com/images/green.jpg" alt="AnotherSite">

</body>
</html>