xxxxxxxxxx
<!DOCTYPE html>
<html>
<head>
<title>Add Icon</title>
<link rel="icon" type="image/png" href="path/to/icon.png">
</head>
<body>
<!-- Rest of your HTML content goes here -->
</body>
</html>
xxxxxxxxxx
// font awsome 6.2.0
// put this link in header in html file
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.0/css/all.min.css" integrity="sha512-xh6O/CkQoPOWDdYTDqeRdPCVd1SpvCA9XXcUnZS2FmJNp1coAFzvtCN9BmamE+4aHK8yyUHUSCcJHgXloTyT2A==" crossorigin="anonymous" referrerpolicy="no-referrer" />
// visite this website 'https://fontawesome.com/' and select you icon is gonna be like that
<i class="fa-solid fa-house"></i>
xxxxxxxxxx
<!DOCTYPE html>
<html>
<head>
<title>Icon Example</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css">
<style>
.icon {
font-size: 24px;
margin-right: 5px;
}
</style>
</head>
<body>
<h1><i class="icon fas fa-star"></i>My Awesome Website</h1>
<p>Welcome to my website. <i class="icon far fa-envelope"></i>Contact me via email or social media.</p>
</body>
</html>