# Map Graph - Disable ScrollZoom & Drag

**URL:** <https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664>\
**Category:** plotly.js\
**Created:** [April 13, 2018, 12:34pm UTC](https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664 "2018-04-13T12:34:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![daizpiri](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/daizpiri/32/2963_2.png) [@daizpiri](https://community.plotly.com/u/daizpiri)\
**Post date:** [April 13, 2018, 12:34pm UTC](https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664/1 "2018-04-13T12:34:51Z")

</div>

Hey there,

I would like to disable ScrollZoom and the dragging in a Map graph.

I’ve double checked all the related info and doc you have and tried adding “{scrollZoom: false}” to the Plotly.newPlot as is described in the documentation and although it works with the line charts no luck with the map’s one…

Then I noticed that you have had troubles with that functionalty to be configured on subplots, haven’t you?

Not sure if what I’m asking is what it’s included in your next product release proposals …\>

[v.2.0.0 wishlist](https://github.com/plotly/plotly.js/issues/420)

I’ve prepared a [codepen](https://codepen.io/Dorkaitz/pen/QmooBK?editors=1010) where I’m trying to set it up

Although it looks for me that what I’m trying to do is not a currently supported functionality, any thoughts to work around it?

to summarize it; basically what I’m looking for is:

- Not allowing the map to zoom-in/out, any kind of dragging functionality but letting it to keep the hover interaction for being able to know what are the points marking to etc (I wanted to change point’s when hovering them)

Thanks in advance guys!

---

<div class="post-metadata">

**Author:** ![etienne](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/etienne/32/17_2.png) [@etienne](https://community.plotly.com/u/etienne)\
**Post date:** [April 13, 2018, 2:22pm UTC](https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664/2 "2018-04-13T14:22:44Z")

</div>

Oh right. That one has already a dedicated issue: [https://github.com/plotly/plotly.js/issues/143](https://github.com/plotly/plotly.js/issues/143)

---

<div class="post-metadata">

**Author:** ![daizpiri](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/daizpiri/32/2963_2.png) [@daizpiri](https://community.plotly.com/u/daizpiri)\
**Post date:** [April 16, 2018, 7:22am UTC](https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664/3 "2018-04-16T07:22:04Z")

</div>

Thanks for your response @etienne !

So, by now, there’s no chance to disable that zoom and dragging functionality in the maps isn’t it?

Regards 😉

---

<div class="post-metadata">

**Author:** ![eddgr](https://avatars.discourse-cdn.com/v4/letter/e/5e9695/32.png) [@eddgr](https://community.plotly.com/u/eddgr)\
**Post date:** [October 31, 2019, 2:29pm UTC](https://community.plotly.com/t/map-graph-disable-scrollzoom-drag/9664/4 "2019-10-31T14:29:51Z")

</div>

You can add `dragmode=False` in your `layout` to disable the drag and zoom. However, users can still access zoom in the hoverbar of plotly.

_edit:_ I realized my solution is for Python but this thread is the top search results for it, so I hope it becomes useful for someone else.
