Hard Hat icon
bx:hard-hat
The Hard Hat icon (bx:hard-hat) is a free SVG icon from the BoxIcons v2 set by Boxicons. It is drawn on a 24 × 24 grid. BoxIcons v2 icons are released under the MIT license, which allows use in personal and commercial projects. Copy it as SVG, JSX, Vue or Svelte code, or download the SVG file.
- Icon set
- BoxIcons v2
- Author
- Boxicons
- License
- MIT
- Size
- 24 × 24
- Tags
- hardhat, bx hard hat
SVG code
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M21 15a9 9 0 0 0-.18-1.81a8.5 8.5 0 0 0-.53-1.69a8 8 0 0 0-.83-1.5a8.7 8.7 0 0 0-1.1-1.33A8.3 8.3 0 0 0 17 7.54a8 8 0 0 0-1.53-.83L15 6.52V5a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v1.52l-.5.19a8 8 0 0 0-1.5.83a8.3 8.3 0 0 0-1.33 1.1A8.3 8.3 0 0 0 4.54 10a8 8 0 0 0-.83 1.53a9 9 0 0 0-.53 1.69A9 9 0 0 0 3 15v3H2v2h20v-2h-1zM5 15a7.3 7.3 0 0 1 .14-1.41a6.6 6.6 0 0 1 .41-1.31a7 7 0 0 1 .64-1.19a7.2 7.2 0 0 1 1.9-1.9A7 7 0 0 1 9 8.68V15h2V6h2v9h2V8.68a8 8 0 0 1 .91.51a7 7 0 0 1 1 .86a6.4 6.4 0 0 1 .85 1a6 6 0 0 1 .65 1.19a7 7 0 0 1 .41 1.31A7.3 7.3 0 0 1 19 15v3H5z"/></svg>How to use the Hard Hat icon
React
import { Icon } from "@iconify/react";
<Icon icon="bx:hard-hat" width="24" />Vue
<script setup>
import { Icon } from "@iconify/vue";
</script>
<template>
<Icon icon="bx:hard-hat" width="24" />
</template>Svelte
<script>
import Icon from "@iconify/svelte";
</script>
<Icon icon="bx:hard-hat" width="24" />Tailwind CSS
<!-- @iconify/tailwind plugin -->
<span class="icon-[bx--hard-hat]"></span>UnoCSS
<!-- @unocss/preset-icons + @iconify-json/bx -->
<div class="i-bx:hard-hat"></div>Web component
<script src="https://code.iconify.design/iconify-icon/2.1.0/iconify-icon.min.js"></script>
<iconify-icon icon="bx:hard-hat"></iconify-icon>HTML image
<img src="https://iconyz.com/api/public/svg/bx/hard-hat.svg" alt="Hard Hat icon" width="24" height="24">Hard Hat icon in other icon sets
Hard Hat icon FAQ
Is the Hard Hat icon free for commercial use?
Yes. BoxIcons v2 icons are released under the MIT license, which allows use in personal and commercial projects.
How do I use the Hard Hat icon in React?
Install @iconify/react and render <Icon icon="bx:hard-hat" />, or use “Copy code” on this page to get a standalone React component.
How do I add the Hard Hat icon to a web page?
Link the SVG file in an image tag: <img src="https://iconyz.com/api/public/svg/bx/hard-hat.svg" alt="Hard Hat icon">, or paste the SVG code inline to style it with CSS.