One month down in 2025: How are your resolutions coming along? Check out how to get back on track here.
Forum Discussion
SWworker
6 years agoExplorer | Level 4
Develop Android app to upload large file to Dropbox. Failed all the times.
Hi,
I currently develop Android app for user to upload their files to Dropbox. My app can upload <300MB file to user's Dropbox account. But large file is failed all the times.
My development environment is Windows 10 and use Android Studio IDE. I had updated dropbox SDK version to 3.1.1 in Gradle build. And refered to official sample code as below:
DbxRequestConfig requestConfig = DbxRequestConfig.newBuilder("APP Name")
.build();
mDbxClient = new DbxClientV2(requestConfig, accessToken);
Then I see the log "com.dropbox.core.BadResponseCodeException: unexpected HTTP status code: 413: null" when error happened. Please help me to fix this issue. Thanks!
When using the individual upload method, only files up to 150 MB are officially supported. Attempting to upload larger files, above 300 MB as you found, will fail with that error.
To upload files larger than 150 MB, you'll need to use upload sessions, via uploadSessionStart, uploadSessionAppendV2, and uploadSessionFinishBatch. Please refer to the documentation for those methods for more information. There's also an example here.
- Greg-DB
Dropbox Staff
When using the individual upload method, only files up to 150 MB are officially supported. Attempting to upload larger files, above 300 MB as you found, will fail with that error.
To upload files larger than 150 MB, you'll need to use upload sessions, via uploadSessionStart, uploadSessionAppendV2, and uploadSessionFinishBatch. Please refer to the documentation for those methods for more information. There's also an example here.
- SWworkerExplorer | Level 4
Hi Greg,
Thank you first.
I have a question about CHUNKED_UPLOAD_CHUNK_SIZE. In sample code, it has a description "Use a multiple of 4MiB for your chunk size". My question is can I set this value smaller than 4MB? Is 32KB ok?
Thanks!!
About Discuss Dropbox Developer & API
Make connections with other developers807 PostsLatest Activity: 22 hours ago
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!