--- title: Icon mdi: true layout: documentation doc-tab: elements doc-subtab: icon variables: - name: $icon-dimensions value: 1.5rem - name: $icon-dimensions-small value: 1rem - name: $icon-dimensions-medium value: 2rem - name: $icon-dimensions-large value: 3rem --- {% capture icon_example %} {% endcapture %} {% capture icon_sizes_example %} {% endcapture %} {% include subnav-elements.html %}

Icons

Bulma is compatible with most icon libraries: Font Awesome, Material Design Icons, etc.

{% include meta.html colors=false sizes=true variables=true %}

Because the icons can take a few seconds to load, and because you want control over the space the icons will take, you can use the icon class as a container:

{% include snippet.html content=icon_example %}
The yellow background is only here for demonstration purposes, to highlight the icon container's area.

The icon container will take up exactly 1.5rem x 1.5rem. The icon itself is sized at 1em.

{% include anchor.html name="Sizes" %}

The Bulma icon container should always be slightly bigger than the font-size used. For example, Font Awesome icons use a font-size of 1em by default, but provides additional sizes.

Container class Container size Font Awesome class Icon size Result
icon is-small 1rem x 1rem fa 1em
icon 1.5rem x 1.5rem fa 1em
icon is-medium 2rem x 2rem fa 1em
fa fa-lg 1.33em
fa fa-2x 2em
icon is-large 3rem x 3rem fa 1em
fa fa-lg 1.33em
fa fa-2x 2em
fa fa-3x 3em
{% include anchor.html name="Icon variations" %}

Font Awesome also provides modifier classes for:

  • fixed width icons
  • bordered icons
  • animated icons
  • rotated & flipped icons
  • stacked icons
Type Font Awesome class Result
Fixed width fa fa-fw
Bordered fa fa-border
Animated fa fa-refresh fa-spin
Rotated & flipped fa fa-shield
fa fa-shield fa-rotate-90
fa fa-shield fa-rotate-180
fa fa-shield fa-rotate-270
fa fa-shield fa-flip-horizontal
fa fa-shield fa-flip-vertical





Stacked {% highlight html %} {% endhighlight %}
{% highlight html %} {% endhighlight %}
{% include variables.html %}