# Choosing a backend database

**URL:** <https://forum.ionicframework.com/t/choosing-a-backend-database/36605>\
**Category:** ionic-v1\
**Created:** [November 9, 2015, 12:17am UTC](https://forum.ionicframework.com/t/choosing-a-backend-database/36605 "2015-11-09T00:17:41Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jamesbyrne](https://avatars.discourse-cdn.com/v4/letter/j/dbc845/32.png) [@jamesbyrne](https://forum.ionicframework.com/u/jamesbyrne)\
**Post date:** [November 9, 2015, 12:17am UTC](https://forum.ionicframework.com/t/choosing-a-backend-database/36605/1 "2015-11-09T00:17:41Z")

</div>

I am trying to decide on a backend for my app. Im building it for a fourth year project and hoping to release it at the end of the college year.

My use case is as follows

- The app will mostly run in the background triggering events at a given time, these events will generate data to be recorded. e.g. every tuesday I generate a set of text and the user can contribute to that or leave it
- The app must store the data locally with the option of synching to a cloud db through a subscription
- The app should work with a fitbit and store that information
- I would prefer to just sync the changes to an object
- I want to store images & video aswell
- I also want to delete information off the phone without deleting from the db to conserve local storage
- I will also be accessing said database from a website

My research had led me to using firebase becaise of its easy to use link ins with Ionic. However its abilities in offline mode have me a bit wary.Other than that I have been looking around at the likes of Backand & recently pouchDB. However I know very little about the other two so I thought I would post here looking for some advice or prior experiences with this kind of application.

---

<div class="post-metadata">

**Author:** ![bengtler](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/bengtler/32/98565_2.png) [@bengtler](https://forum.ionicframework.com/u/bengtler)\
**Post date:** [November 9, 2015, 7:15am UTC](https://forum.ionicframework.com/t/choosing-a-backend-database/36605/2 "2015-11-09T07:15:33Z")

</div>

so if i read your requirements couchdb should be one of your favs for this project.

PouchDB is a ClientSide wrapper for the dbs CouchDB --\> so you have CouchDB at your backend (i would prefer it - but there is already a PouchDB server as node module) and you are using PouchDB in your app. With PouchDB syncing is very easy, but in your case you need to add a little bit logic to be able to remove everything on clientside without effecting the real db.

You can also store any kind of data in a PouchDB:  
[http://pouchdb.com/guides/attachments.html](http://pouchdb.com/guides/attachments.html)

---

<div class="post-metadata">

**Author:** ![jamesbyrne](https://avatars.discourse-cdn.com/v4/letter/j/dbc845/32.png) [@jamesbyrne](https://forum.ionicframework.com/u/jamesbyrne)\
**Post date:** [November 9, 2015, 9:48pm UTC](https://forum.ionicframework.com/t/choosing-a-backend-database/36605/3 "2015-11-09T21:48:42Z")

</div>

Hi Bengtler,

Thanks for the recommendation. I am currently looking into pouchDB and couchDB. Do you have any recommendations for getting started with the two? Or any tips/things to avoid?

---

<div class="post-metadata">

**Author:** ![bengtler](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/bengtler/32/98565_2.png) [@bengtler](https://forum.ionicframework.com/u/bengtler)\
**Post date:** [November 10, 2015, 6:38am UTC](https://forum.ionicframework.com/t/choosing-a-backend-database/36605/4 "2015-11-10T06:38:43Z")

</div>

nope nothing special ^^.

Play a little bit around with it --\> try and error.

If something is unclear or you have problems feel free to ask.
