# Keep graph aspect ratio while zooming?

**URL:** <https://community.plotly.com/t/keep-graph-aspect-ratio-while-zooming/976>\
**Category:** plotly.js\
**Created:** [May 4, 2016, 1:49pm UTC](https://community.plotly.com/t/keep-graph-aspect-ratio-while-zooming/976 "2016-05-04T13:49:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Linda](https://avatars.discourse-cdn.com/v4/letter/l/67e7ee/32.png) [@Linda](https://community.plotly.com/u/Linda)\
**Post date:** [May 4, 2016, 1:49pm UTC](https://community.plotly.com/t/keep-graph-aspect-ratio-while-zooming/976/1 "2016-05-04T13:49:21Z")

</div>

We are using plotly to draw the geometry of an electrical device. When the user zooms in, I would like to keep the aspect ratio of the x-axis and y-axis constant so the geometry does not look distorted. Is this feature available in plotly or plotly 2.0? Thanks!

---

<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:** [May 5, 2016, 1:20pm UTC](https://community.plotly.com/t/keep-graph-aspect-ratio-while-zooming/976/2 "2016-05-05T13:20:24Z")

</div>

We’re planning on adding this feature in the next few months.

Subscribe to [https://github.com/plotly/plotly.js/issues/272](https://github.com/plotly/plotly.js/issues/272) for the latest development info.

---

<div class="post-metadata">

**Author:** ![jack](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/jack/32/11_2.png) [@jack](https://community.plotly.com/u/jack)\
**Post date:** [December 23, 2017, 1:52am UTC](https://community.plotly.com/t/keep-graph-aspect-ratio-while-zooming/976/3 "2017-12-23T01:52:05Z")

</div>

JS example here (scroll to bottom):

> **[Axes](https://plot.ly/javascript/axes/#fixed-ratio-axes)**
>
> How to adjust axes properties in D3.js-based javascript charts. Seven examples of linear and logarithmic axes, axes titles, and styling and coloring axes and grid lines.

Python example here:

> **[Axes](https://plot.ly/python/axes/#fixed-ratio-axes)**
>
> How to adjust axes properties in python. Seven examples of linear and logarithmic axes, axes titles, and styling and coloring axes and grid lines.
