# How to plot an image?

**URL:** <https://community.plotly.com/t/how-to-plot-an-image/1807>\
**Category:** Plotly Fundamentals\
**Created:** [August 10, 2016, 9:53pm UTC](https://community.plotly.com/t/how-to-plot-an-image/1807 "2016-08-10T21:53:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![malmaud](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/malmaud/32/479_2.png) [@malmaud](https://community.plotly.com/u/malmaud)\
**Post date:** [August 10, 2016, 9:53pm UTC](https://community.plotly.com/t/how-to-plot-an-image/1807/1 "2016-08-10T21:53:35Z")

</div>

I have an image (eg, a 3d array with width, height, and 3 color channels). How can I plot that image, similar to MATLAB’s `imshow`? Would I be correct in saying the closest I can do now is convert it to grayscale and plot that as a heatmap?

---

<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:** [August 11, 2016, 2:33pm UTC](https://community.plotly.com/t/how-to-plot-an-image/1807/2 "2016-08-11T14:33:55Z")

</div>

Unfortunately, plotly doesn’t currently offer an `imshow` function.

You’ll need to convert you color channels into a heatmap `z` 2D array.

---

<div class="post-metadata">

**Author:** ![ilovecheese](https://avatars.discourse-cdn.com/v4/letter/i/34f0e0/32.png) [@ilovecheese](https://community.plotly.com/u/ilovecheese)\
**Post date:** [December 4, 2018, 9:52pm UTC](https://community.plotly.com/t/how-to-plot-an-image/1807/3 "2018-12-04T21:52:59Z")

</div>

Now it is possible to plot images using the the layour.image feature.

See demo here: [https://plot.ly/python/images/](https://plot.ly/python/images/)

---

<div class="post-metadata">

**Author:** ![Emmanuelle](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/emmanuelle/32/7853_2.png) [@Emmanuelle](https://community.plotly.com/u/Emmanuelle)\
**Post date:** [November 27, 2019, 9:36pm UTC](https://community.plotly.com/t/how-to-plot-an-image/1807/4 "2019-11-27T21:36:30Z")

</div>

We have an `imshow` function now [https://plot.ly/python/imshow/](https://plot.ly/python/imshow/)
