# Overlap scatter chart and area chart

**URL:** <https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394>\
**Category:** plotly.js\
**Created:** [December 10, 2019, 2:12pm UTC](https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394 "2019-12-10T14:12:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Zolotoy](https://avatars.discourse-cdn.com/v4/letter/z/6bbea6/32.png) [@Zolotoy](https://community.plotly.com/u/Zolotoy)\
**Post date:** [December 10, 2019, 2:12pm UTC](https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394/1 "2019-12-10T14:12:13Z")

</div>

I have the following example:  
[https://codepen.io/MZolotoy/pen/xxbVwEo](https://codepen.io/MZolotoy/pen/xxbVwEo)

The line that is underneath of area changes it color. Can I keep it same color?

Thanks

---

<div class="post-metadata">

**Author:** ![Zolotoy](https://avatars.discourse-cdn.com/v4/letter/z/6bbea6/32.png) [@Zolotoy](https://community.plotly.com/u/Zolotoy)\
**Post date:** [December 10, 2019, 2:47pm UTC](https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394/2 "2019-12-10T14:47:13Z")

</div>

I figure it out. Trace order is defined by the trace array. So adding an area chart before the line did the trick.

---

<div class="post-metadata">

**Author:** ![archmoj](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/archmoj/32/8388_2.png) [@archmoj](https://community.plotly.com/u/archmoj)\
**Post date:** [January 21, 2020, 9:52pm UTC](https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394/3 "2020-01-21T21:52:46Z")

</div>

You may reverse the draw order.  
[demo](https://codepen.io/MojtabaSamimi/pen/rNaoYpK?editors=0010).

---

<div class="post-metadata">

**Author:** ![Lo96](https://avatars.discourse-cdn.com/v4/letter/l/f6c823/32.png) [@Lo96](https://community.plotly.com/u/Lo96)\
**Post date:** [December 3, 2024, 8:58am UTC](https://community.plotly.com/t/overlap-scatter-chart-and-area-chart/32394/4 "2024-12-03T08:58:03Z")

</div>

how can i do this in python ?
