Train icon
pepicons:train
The Train icon (pepicons:train) is a free SVG icon from the Pepicons set by CyCraft. It is drawn on a 20 × 20 grid. Pepicons are released under the CC BY 4.0 license, which allows use in personal and commercial projects as long as you credit the author. Copy it as SVG, JSX, Vue or Svelte code, or download the SVG file.
SVG code
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20"><g fill="currentColor"><path fill-rule="evenodd" d="M17.5 5a4 4 0 0 0-4-4h-7a4 4 0 0 0-4 4v6.99a4 4 0 0 0 2.814 3.82c1.558.483 3.121.726 4.686.726s3.128-.243 4.686-.727a4 4 0 0 0 2.814-3.82V5Zm-13 6.99V5a2 2 0 0 1 2-2h7a2 2 0 0 1 2 2v6.99a2 2 0 0 1-1.407 1.91a13.733 13.733 0 0 1-4.093.636a13.73 13.73 0 0 1-4.093-.637A2 2 0 0 1 4.5 11.99Z" clip-rule="evenodd"/><path d="M8 12a1.5 1.5 0 1 1-3 0a1.5 1.5 0 0 1 3 0Zm7 0a1.5 1.5 0 1 1-3 0a1.5 1.5 0 0 1 3 0ZM4.581 15.147a1 1 0 1 1 1.841.781l-1.475 3.475a1 1 0 1 1-1.84-.781l1.474-3.475Zm10.887-.494a1 1 0 0 0-1.876.694l1.47 3.97a1 1 0 0 0 1.876-.694l-1.47-3.97Z"/><path fill-rule="evenodd" d="M15 6a2.5 2.5 0 0 0-2.5-2.5h-5A2.5 2.5 0 0 0 5 6v1.535a2.5 2.5 0 0 0 2.076 2.463c.974.168 1.949.252 2.924.252c.975 0 1.95-.084 2.924-.252A2.5 2.5 0 0 0 15 7.535V6ZM7 7.535V6a.5.5 0 0 1 .5-.5h5a.5.5 0 0 1 .5.5v1.535a.5.5 0 0 1-.415.492a15.161 15.161 0 0 1-5.17 0A.5.5 0 0 1 7 7.535Z" clip-rule="evenodd"/><path d="M4.75 18.25v-1.5h10.501v1.5H4.75Z"/></g></svg>How to use the Train icon
React
import { Icon } from "@iconify/react";
<Icon icon="pepicons:train" width="24" />Vue
<script setup>
import { Icon } from "@iconify/vue";
</script>
<template>
<Icon icon="pepicons:train" width="24" />
</template>Svelte
<script>
import Icon from "@iconify/svelte";
</script>
<Icon icon="pepicons:train" width="24" />Tailwind CSS
<!-- @iconify/tailwind plugin -->
<span class="icon-[pepicons--train]"></span>UnoCSS
<!-- @unocss/preset-icons + @iconify-json/pepicons -->
<div class="i-pepicons:train"></div>Web component
<script src="https://code.iconify.design/iconify-icon/2.1.0/iconify-icon.min.js"></script>
<iconify-icon icon="pepicons:train"></iconify-icon>HTML image
<img src="https://iconyz.com/api/public/svg/pepicons/train.svg" alt="Train icon" width="24" height="24">Related icons in Pepicons
Train icon in other icon sets
Train icon FAQ
Is the Train icon free for commercial use?
Yes. Pepicons are released under the CC BY 4.0 license, which allows use in personal and commercial projects as long as you credit the author.
How do I use the Train icon in React?
Install @iconify/react and render <Icon icon="pepicons:train" />, or use “Copy code” on this page to get a standalone React component.
How do I add the Train icon to a web page?
Link the SVG file in an image tag: <img src="https://iconyz.com/api/public/svg/pepicons/train.svg" alt="Train icon">, or paste the SVG code inline to style it with CSS.