---
layout: api
title: "v2.1.3 JavaScript Library: L.Icon"
categories: api
version: v2.1.3
permalink: /api/v2.1.3/l-icon/
---
<h2 id="icon">Icon</h2>

<p>Represents an icon to provide when creating a marker.</p>

<pre><code class="javascript">var myIcon = L.icon({
	iconUrl: 'my-icon.png',
	iconRetinaUrl: 'my-icon@2x.png',
	iconSize: [38, 95],
	iconAnchor: [22, 94],
	popupAnchor: [-3, -76],
	shadowUrl: 'my-icon-shadow.png',
	shadowRetinaUrl: 'my-icon-shadow@2x.png',
	shadowSize: [68, 95],
	shado