# Storage for shared data among pages

**URL:** <https://forum.ionicframework.com/t/storage-for-shared-data-among-pages/150166>\
**Category:** ionic-v3\
**Created:** [December 12, 2018, 8:32pm UTC](https://forum.ionicframework.com/t/storage-for-shared-data-among-pages/150166 "2018-12-12T20:32:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sadalsuud](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/sadalsuud/32/109533_2.png) [@sadalsuud](https://forum.ionicframework.com/u/sadalsuud)\
**Post date:** [December 12, 2018, 8:32pm UTC](https://forum.ionicframework.com/t/storage-for-shared-data-among-pages/150166/1 "2018-12-12T20:32:15Z")

</div>

Hi people… I am new in Ionic, I have a dude: I have a provider with a variables. In a first page I do changes values of these variables, after in second page I like read the provider’s variables but I do not know how.

Meanwhile I use the storage for this. Exists any another form more elegant? … Thanks for the time. I’m attent

---

<div class="post-metadata">

**Author:** ![rapropos](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/rapropos/32/100227_2.png) [@rapropos](https://forum.ionicframework.com/u/rapropos)\
**Post date:** [December 12, 2018, 8:54pm UTC](https://forum.ionicframework.com/t/storage-for-shared-data-among-pages/150166/2 "2018-12-12T20:54:05Z")

</div>

> [@sadalsuud](#):
>
> Exists any another form more elegant?

Absolutely. Storage is a really bad fit here due to race conditions. Use a mutually injected service as described in [tour of heroes 4](https://angular.io/tutorial/toh-pt4).

---

<div class="post-metadata">

**Author:** ![mhartington](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/mhartington/32/137757_2.png) [@mhartington](https://forum.ionicframework.com/u/mhartington)\
**Post date:** [July 19, 2021, 9:03pm UTC](https://forum.ionicframework.com/t/storage-for-shared-data-among-pages/150166/3 "2021-07-19T21:03:57Z")

</div>


