Google Photos like backup of photos from iPhone?

Hey guys

I need your help please?

I need a way to backup photos from my family’s iPhones to Nextcloud in a fashion similar to Google photos?

With google photos it auto uploads to the cloud, however once they are uploaded, should I decide to delete them from my iPhone gallery, they are still accessible from Nextcloud? The wording on the app setting for iPhone leaves a little bit of confusion.

So to repeat I want to be able to:

  1. Take photo >>>>> 2) Nextcloud app uploads to my Nextcloud server >>>> 3) Delete photo from iPhone gallery app >> >> 4) Be able to recover a backup copy from my server or still view from within the Nextcloud app it will just have to download a copy from the cloud. However I do not want it to be deleted from my server unless I specifically go into the next cloud app and select it for deletion?

I do apologise if there is already an answer to this on the forums. I do very much appreciate your help and guidance. Id much rather my data be in my own private cloud than googles.

Many thanks