Documentation versions (currently viewingVaadin 14)

You are viewing documentation for an older Vaadin version. View latest documentation


The Icon component allows you to display an icon. You can use icons from Vaadin icons, PolymerElements/iron-iconset-svg or any other set.

Using Icon

Icon is normally used with the default VaadinIcon enumeration which maps all the icons from vaadin-icons.

Example: Creating a Vaadin logo icon.

Icon icon = VaadinIcon.VAADIN_H.create();
new Button("Vaadin", icon);

You can also use an Icon from another collection.

Example: Creating a "clock" icon from the vaadin-lumo-styles collection.

Icon icon = new Icon("lumo", "clock");
new Button("Clock", icon);