- Home /
Downloading large files from AWS S3 to Android
My app needs to download some large video files when it first opens. The videos are stored on Amazon S3. I installed the Amazon Unity SDK and set up Cognito and I can use it to download the files on the PC, but on android I get out of memory errors while writing the file stream. I've tried several different approaches to writing the file stream, but no matter what it seems that the whole file is ending up in memory.
I contacted Amazon about this and it seems I'm not the only one having this problem. They suggested that I use a pre-signed url. Unfortunately the Unity SDK client object doesn't have a method for getting a pre-signed url. The Amazon .net sdk has it, but I haven't figured out how to integrate that.
I'm desperate for any solution at this point and looking for options.
Tl;dr: Has anyone had luck downloading large files from S3 onto android, and if so how did you do it?
I have the same problem but with unity-iOS, maybe the problem occurs when sdk finish the download and create a Stream from www.bytes object (check the sources)
Did you tried this plugin?
https://assetstore.unity.com/packages/tools/network/large-file-downloader-cross-platform-92128
Your answer
![](https://koobas.hobune.stream/wayback/20220612063737im_/https://answers.unity.com/themes/thub/images/avi.jpg)