How to make icons bigger

Making icons bigger on your web pages can improve visibility and accessibility, ensuring they catch the user's attention. There are several methods to increase the size of icons, each offering different levels of control and flexibility. In this article, we'll explore different techniques to enlarge icons using CSS, HTML attributes, and Bootstrap classes.


Using Bootstrap

Font Awesome is a popular icon library that makes it easy to add scalable icons to your web pages. You can control the size of Font Awesome icons using classes.

To increase icon sizes relative to their container, use fa-xs, fa-sm, fa-lg (33% increase), or use literal sizes (to scale it from 1x to 10x) fa-2x, fa-3x, fa-4x, fa-5x, fa-6x, fa-7x, fa-8x, fa-9x, fa-10x.

        
            
        <i class="fas fa-camera fa-xs"></i>
        <i class="fas fa-camera fa-sm"></i>
        <i class="fas fa-camera fa-lg"></i>
        <i class="fas fa-camera fa-2x"></i>
        <i class="fas fa-camera fa-3x"></i>
        <i class="fas fa-camera fa-4x"></i>
        <i class="fas fa-camera fa-5x"></i>
        <i class="fas fa-camera fa-6x"></i>
        <i class="fas fa-camera fa-7x"></i>
        <i class="fas fa-camera fa-8x"></i>
        <i class="fas fa-camera fa-9x"></i>
        <i class="fas fa-camera fa-10x"></i>
        
        
    

Using Inline CSS Styles

You can control the size of icons directly using inline CSS styles. This method is useful for quick adjustments and precise control.

  • Use the style attribute to apply inline CSS directly to the icon.
  • Set the font-size property to specify the icon size in pixels.
  • This method allows for precise control over the icon size.

        
            
        <i class="fas fa-home" style="font-size: 24px;"></i>
        <i class="fas fa-home" style="font-size: 36px;"></i>
        <i class="fas fa-home" style="font-size: 48px;"></i>