 <p>You need to do something like this:</p> <pre><code>//define base layers var osmUrl='http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png'; var normalView = L.tileLayer(osmUrl, {styleId: 997, attribution: osmAttributes, maxZoom: 18 }); ... //define overlay layers var markersLayer = new L.layerGroup(); var linesLayer = new L.layerGroup(); ... //create MAP with default base and overlay layers var map = L.map('map', { layers: [normalView, markersLayer] }).setView([45.2516700, 19.8369400], 12); //add layers to the base and overlay var baseMaps = { "Normal view": normalView, "Night view": nightView, "MapQuest layer": mapQuest }; var overlayMaps = { "Markers": markersLayer, "Lines": linesLayer, "3D layer": osmbView }; //add layer control to the map L.control.layers(baseMaps, overlayMaps).addTo(map); </code></pre>