{"id":1513,"date":"2022-11-15T12:07:11","date_gmt":"2022-11-15T12:07:11","guid":{"rendered":"https:\/\/www.workfall.com\/learning\/blog\/?p=1513"},"modified":"2025-09-24T10:23:31","modified_gmt":"2025-09-24T10:23:31","slug":"how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend","status":"publish","type":"post","link":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/","title":{"rendered":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?"},"content":{"rendered":"<span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span>\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/hIFb7sMi52XL-9ww6ZRWhLj79yyM_NieIWQ1Urs3RzVsrst74AR_1sqCXc1ja1Cvlujk0GKNJgeup5Ph0IZrqkhYkx_WqeLK8Tq1CUX3Ghtbs-GNj3XU_XbH5975lATJlM_Ivu9fc0vlOCKU0MNAkkQ0nFxST19PmBINAmZ4xRbumwPHef3sRvOE3bGMKg\" alt=\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?\"\/><\/figure>\n\n\n\n<p class=\"has-text-align-justify\">When dealing with file uploads, you must be aware that files are uploaded in buffers stored in memory and if the file is larger than the allocated memory in your VM, it may run out of memory and the application might crash. For example, if your allocated memory is 2GB, if you try to upload a file 2GB in size, the memory will max out.<\/p>\n\n\n\n<p class=\"has-text-align-justify\">This calls for a change in how we carry out file uploads. As a result, multipart uploads have come to the rescue. We shall look at how we can write code on both the server and the client to accept multipart file uploads. On the client side, we shall use React and NestJS on the server side. We shall also use an S3 bucket for storing our files.<\/p>\n\n\n\n<p class=\"has-text-align-justify\">NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS. As it helps to break down the most complex of structures and work with individual components. <a href=\"https:\/\/www.workfall.com\/learning\/blog\/create-vaults-in-aws-s3-glacier-to-store-and-archive-data\/\">AWS S3<\/a> is used for scalable object storage in the cloud and provides data availability, security, and performance that are unmatched in the market. These objects are often stored in binary format. We shall use the <code>aws-sdk<\/code> npm package to interact with Amazon S3 in this blog.<\/p>\n\n\n\n<p>In this blog, we will demonstrate how to<\/p>\n\n\n\n<ol><li>configure AWS S3 buckets<\/li><li>write server-side applications using NestJS<\/li><li>write client-side applications using ReactJS<\/li><\/ol>\n\n\n\n<h2>Hands-on<\/h2>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/szmWibyeeOZ0XVG3H2D0YgWH39o8hA6EIDESx6zFy56ly1DfRpDM7kFqnYD6MceJ1KrnSdeXYUj257zvk8RUqw7xGIZg-WGfKSEBSySzbg1YWj2h7jzLRIkl4am7JqwVaDn2a6pXmoU8ovjtZHXcYX8cqnSgGcm01Zko_fIpXf4H10edddjHhfNWAa3D_g\" alt=\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?\"\/><\/figure>\n\n\n\n<p>In this hands-on, we will be implementing the following:<\/p>\n\n\n\n<ol><li><strong>Creating a multipart upload<\/strong> &#8211; This makes a call to AWS S3 to create a unique uploadId which will be used to trace the parts that are being uploaded back to the original file for consolidation purposes.<br><\/li><li><strong>Uploading parts<\/strong> &#8211; This is the main part where the file chunks are uploaded and part of the metadata in this operation is the uploaded.<br><\/li><li><strong>Multipart upload completion <\/strong>&#8211; This is where the file is consolidated back into one complete object in S3 using the various parts that were uploaded.<\/li><\/ol>\n\n\n\n<p><strong>Let\u2019s configure the AWS S3 bucket:&nbsp;<\/strong><\/p>\n\n\n\n<p class=\"has-text-align-justify\">We shall begin by creating an S3 bucket as shown in the following image. You can type in the search bar in the top navigation; \u201cS3\u201d.<\/p>\n\n\n\n<p>Give your bucket a name, select a region, and use all the other default values\/configurations.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/ZKr-6FmXDrKCABGS6RuqpElZrviKrxmUxe4h5fpLnKMTr6ZD1MsmEugCHwn9YAfLOmfVffszC9tyR5MTRQnHjg8BCI1SHwqnVaLu6OcA2vxgqF9-RfXXUbbQJVGAFkME4Our0QuLvpCbtI8fHczghSgWnlOY9MxPMGIKb52UkY_5xOTrJLcfN56M098v2g\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/zBJUQns18j-HVLS7mnw3rmYkYfhFs8o9qkz7GgK3NrgCI8JJ16-OThjA0M-Y3r1WGivR7pKMFowd5Aa-NTFedKOa3GAWa9PD627Cl-dsQd8vb5aNTDuXJSW7gZ-s7-wNKPT5J41z8KqSrG4QllG8tKOVH608fwQEB-lwtxoJe3GU6y6XcY3kT_1G8vderQ\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/vrNf8v1WNwU72OBPz8EcyprJuxjGUYODcm2Xku8XieFRvmCvCO2m3ap7CmTiMQmFjD_xdp_NPkLuZ8lNoNsjJWBjnJlO68x6vDCjhg3qM_kJu8VtxspiQa1qFO63_LET00NHYUrsZs5eAMbEzpZp8zTxOtWQZInSn2wopY4pDzWaWaqLXJMxYfxB6qkP8g\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p>Next, we need to Edit the CORS configuration for our S3 bucket as shown below.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/Qy9GVN_RxIokz82_aNL7qUiVMi9CSHb585bW2pmPZfgvQ6pMf-SCIJx5w2_zqcU_0nmypzumc7nqE2nZtrAuBK9zWi9wL-sy1yXTVhUADXXZclxAO_BbjvLuZJBxHDijI4BBw2JHZc9_ct-CQs__VmONsHFwem3Dv5C-ZXjediv1_nmejOXJhYFUe41PhQ\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p class=\"has-text-align-justify\">We now need to create a new User Group and Assign them a policy that grants access to S3. Click on Create Group.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/ZGJRBvO_CIJc2QtWvS5qxCGx8PcBDAAdJS4zSHNsX683fN5kMWlj9KVeocVA4IEKq5HUTNARh1rVChQYwRtr5kOUPnjNigvzTfZhN6HNRWCCIdNih2TZSDWOvFxWQ6Iif1s1ZFntQrii2IKuxsl-dUIBwqdd4kFGpjgE-oMC3vHpJ8VdoRt9Bl30FY3Exg\" alt=\"\"\/><\/figure>\n\n\n\n<p>Select The checked permission policy as shown below.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/l8SJetkG4fYCUXe-R4rXEtWlg8ukaNbA05_U628hsOyYGAKJovnv2xEhdzjua0BWz7sINJxD9_bbYSHRBcOfVEtWfHRKXK8MNpItjrFpxsxolJP8S85ZEXc9aakw4b0qNSVQ6OpDqKxklmW5mCyDh88s9hZB_4N95zCBeBzYqhLLyi4skBiU3BaIMqQAHQ\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p class=\"has-text-align-justify\">We can create a new user and add them to the User Group with Full S3 access. Click on Add users and give your user a name.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/th1AiphCpN_Q4hm2YmLb3U0cD2b6nujvv3sFFN-Mqp1BcoegEsKqYCLJxgLl1KmjaWYAb_4n2JhXTjgUUGN-ak4hXbB6mRlYb8qwXCmdkF6c1vj4emO64GZCasfFcwGxoSB4pEb9c_hjA7cWetQCMlqBEf8kBDrFc7lMe8owu-puNQsRmDuUtKtPbJ069A\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/ttRtFRRDzMntMttm3W9NIHOfp5H2MgO0Rt0kZUIMhCLXGVATNgJInBc9YebQB5b-AfrU6aIeUJ3DQoMAndswPEB8ikbzQYTk19q5JYjzny1D3_9WjIEnp09ySl4gdhkpAIm3kpH-XySSeKtCRMUrmUsn1GlNGB68Y2EWoEkjODn7PDKDJIxqDuxjgu3hZw\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p>You can skip the tags and go straight to click on Create user.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/5XHnNyE2HEA5Qc2npcjlxxc10R8Ho2T9x4IxavP5DWLaF_3Va6_8yIuGA_PP3I5tX2dn1kCiS91WziyeZnDNgkO_pY-2x7StDCX4H3zU_AhQwMfHcefwa7kCHZuCU5UBd3EpKigvihK3M-vIgvbEjopME7gcWEpGVjEpiLXN-JveK_ihkignGKH1I2Mzgw\" alt=\"\"\/><\/figure>\n\n\n\n<p><strong>Server Side Application(NestJS)<\/strong><\/p>\n\n\n\n<p>Code repository &#8211; <a href=\"https:\/\/github.com\/workfall\/multipart-upload-backend\">https:\/\/github.com\/workfall\/multipart-upload-backend<\/a><\/p>\n\n\n\n<p>Back on the server-side code (NestJS), we will use microservice architecture.<\/p>\n\n\n\n<p><code>maint.ts<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/ag8kgVElAguvseUmK9joFy7ao5Zly-NQnM7fCk8D2zXbDA9Tyng00CxiuvnRbRCF2XNhMJZDm7iXtGzikKVQqFJeRyuFAb3nDxODBwi4OEB2HD9qWtPw300VBXCLop1CRVI4ALgTE3oBmlUfM8mYM38BqiiBrH6JI5BnY6u84qQ6J5cexE2Dp2ez4rtatA\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p><code>shared-service.service.ts&nbsp;<\/code><\/p>\n\n\n\n<p>This is the part that <code>aws-sdk<\/code> comes into play.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/pGrqO8I55FyAkQ2ThHpZbPEpaUVd07Abuucg8hJnhxiMAtslE_V6AFIwmbgsn_i3WQ-Uv4gVhDjfKpjtd7Ozsegq39RhviQGh8S6623PjNRNfkFIzNsXe3zQTAkwJZoF-UlNlR228qoP8V0e1S--TC5ioBfQ0Ug6yqs-f54Mu78bVINCxFrPfaf7ciNCFA\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/w-XI7M3dGO6XExJISA5Y0JRB1oDGXGf-fqrE5nSNzgcugIucA1fuz5dTwx4CCC0ek_fYPYLyhN8rvkmYGYZMG8FK9AsMq7zhnj8pyoHy-AbkKUZ42XGeCRGS6lVCJ1FegUfXm3FPvTMzZaxEqbYKc9CDBAKLyotE689q07QAT7tlE5qaQwAsPkVwUjbo7Q\" alt=\"\"\/><\/figure>\n\n\n\n<p><code>shared-service.controller.ts&nbsp;<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh4.googleusercontent.com\/h_c7Q1j-ok-EEz5IgHeqoNk8zCHAx8MNsIKV5y21j9JKpRJhTK4_ca-nX0FlF40-oYVfaR0qXYVE64gWuNZ8R0WpnBtht5xNTy6h34w9rNdd0rRcOSzeHKoHNMbX5TCfsOOgJDpgKfybHmGS2BVxPj9-E9q3ahnjxfflW7RMlUc77C-8gh6OxsN4Z1mEXg\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p><strong>Client Side Application (React)<\/strong><\/p>\n\n\n\n<p>Code repository &#8211; <a href=\"https:\/\/github.com\/workfall\/multipart-upload-frontend\">https:\/\/github.com\/workfall\/multipart-upload-frontend<\/a><\/p>\n\n\n\n<p class=\"has-text-align-justify\">On the client side, we shall consume the endpoints we created and also most importantly determine the number of chunks a given file will have. Which will also be used to get pre-signed URLs for each part being uploaded.<\/p>\n\n\n\n<p class=\"has-text-align-justify\">After all the chunks have been uploaded we have to send a request to S3 to complete the upload of the file and put together the chunks to form one file. If not, S3 will assume that the upload is incomplete and you won\u2019t see your file in the AWS console.<\/p>\n\n\n\n<p><code>FileUploadComponent.tsx&nbsp;<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/YfY1LYvVv18cHF2DoISQIeqXL8urOsPgzDSHo3EdH9vaqBxMuai3aB-2mVkBXyErakTe89dpxMNcO2TezohDYh4CpBA9uqWSP36Fumtl6l40fg0jEtCqLAn0EQispSlvRTvUfuhy2njjPsoxW-ebaS7KUHFquS99PkQBZEeh60nrtYVIabC93ZsRCCDUAQ\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p><code>Uploader.tsx<\/code><\/p>\n\n\n\n<p class=\"has-text-align-justify\">This file has all the logic to deal with uploading the file. It gets the chunks of the file, gets a pre-signed URL for each part, and gives it a part number. The parts are sent as chunks using the pre-signed URL.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/xiHd_AlykY_CRpXrjjf9RHUC1fS4qTj2k03x7B8aMxZZVjDppYTwPWV_UfZ0rQHgmpA26j93Fs5UePFv_IJ4NrbCHmBNClb2lSljEjSEhjmeAp7wZUVDdpMuB0GI3fLvXxaQDOyQDzqJmQ98H5Xw-z29R0t8JW49jtw57lpulSc1V6zWGaSF_EW3C7b6kg\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/GXrwv1nkkS1zKLxcSe3Oejg0ErdEL9WXcwQYW0kXJYSikOug8AglDD57x3mHOiSYRgW746vyNGX8ZC9nwCMvx0WoqGlMlbvPXbZrsl6JvtzLP1APBpzUOS3oXepFS1M4bfDQrLBl9eyNUe4oa0p0sVPSsTLPBamxz9OpiFdUL85GjfHSShHKE9u7E8MQSA\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/J2GoIGSI4trZDp5yvE1enGZyww9Iw1D74Y8s4USFXSrPeQZuviI6Wx0jIrNb9RzhCcmBTiNmQZSJlJ26UftLieMg8DiQwdhVbWRqgFiKId5E1qce1nbWRVXmoij3Vv9Zh_a15ecJT5VlIuMCWgrtOn50fEBXbGkMebJtacWh3dh6x3wWH6bNCG4Ph0uSmg\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/lxZWR4MO6eWmbK3UglmtigOa4A0O6JlRap0Jf6c-L4dm2GlRHioXflvVQHj3_WwINdzkJHLHruLsQ2XbZF4LNXsETWzWp9Q3XayeJqMRf1arowE0gz1a-O0iJUu3rrbV2_fsEyZpfNBDF82j-Hrevb1a4UxUymcXYdn9WY_1Wjs0UJJLTSKV9aP9WwaEdw\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/FZ_uZSDw1OAma6OEixuPKnCkeFarpiF6foERBgaIBq6EOWh6flBcG8bH2wNDNLdk5YMqzp4pXqxjU69n3ESddkl9H6M0Cv9v-nHpzdDWK369JBi1w_5XjmsfpYf__EUzpu00lo4J0uXbARpdwoodjHzR9ft8TDuK5az-etNY7TZU-eXfvUZ0wtI1haXtmw\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/6Ss4-19k0ayeomWIZnVNnGKxtE0PL8NhxxnhlyAMnJpZAPjYXnUjelgzESvU3JlhEDWc_qT3A_tK88qk9tUAYv-Ldy9G4SgUmFUPtPG-SyhYHDefsnDYigILfw6dalDuCoMOhEQgElxt1WEjxhSmzH9KeHJDuXvX0ZlnnuJx1c-K7bSpC7dvAVpc75vkyg\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh5.googleusercontent.com\/vvyMjHE5tJJ_a60RB-4DQHt9619yCGVuiuFJl2LBXILvKNjCkHog1Sw4GHPw4DpqNCd3-BbnC44Qd8jFuvBPd2NKyATP2vMjwWl_KHB8WxQfYJBYPpcVwPczWfQ5WOeDE0saybj-hHbUUnhlPJnMp_fjbOkXxfeSAibBx260eAS3Muo9NpjvbC-kjjjNuQ\" alt=\"upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)\"\/><\/figure>\n\n\n\n<p><code>App.tsx<\/code><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh3.googleusercontent.com\/oAltWFr4zun6kOW68BgW1WnBtMufjQOykrRPZghuWeevNyOBnJm7RqJCLqSW76jNwVdpbLbLoXvU4bLHonB2k5RR_3YwifutmTpsJlWXBB98XLqV0h755zL_2W0oEdSTFfWOy3oOle1XdtQv3fTpsovImDT0n7r8lqin_H-KvOsznXvner4h1Dp_MmzWhQ\" alt=\"\"\/><\/figure>\n\n\n\n<figure class=\"wp-block-image\"><img src=\"https:\/\/lh6.googleusercontent.com\/hZyWAxXq-mJBd3j44BOAuHeyKStD2AGJpOlMn0bZ-iGQZ3gASwnUxZbjzrXnOLWb--IQtB7bzkcf7irvcA4FWjtoIABaO4g2h_EaWI7JjVziJVVZcXZ75j5SdUVcl_m97KPnr7o7sPWywF5uWBBUxxY9Umx2l75MP91fZXOFJpBl6Jsv0sGDz5CtRChl8w\" alt=\"\"\/><\/figure>\n\n\n\n<h2>Conclusion<\/h2>\n\n\n\n<p class=\"has-text-align-justify\">In this blog, we looked at how to perform multi-part uploads to Amazon S3 using ReactJS frontend and NestJS backend. The multi-part upload method with pre-signed URLs is ideal for very large files and it is also secure because the pre-signed URL is usually short-lived. Summary:<\/p>\n\n\n\n<ul><li>Create file chunks (client-side)<\/li><li>Create multipart upload<\/li><li>Obtained pre-signed URL for each part\/chunk<\/li><li>Complete muti-part upload<\/li><\/ul>\n\n\n\n<p class=\"has-text-align-justify\"><strong>Note: <\/strong>Always remember to clear incomplete parts for multipart uploads in order to prevent extra charges on AWS. You can do that in the Storage Lens tab in the S3 console. We will come up with more such use cases in our upcoming blogs.<\/p>\n\n\n\n<p><strong>Meanwhile\u2026<\/strong><\/p>\n\n\n\n<p class=\"has-text-align-justify\">If you are an aspiring developer and want to explore more such topics, here are a few of our blogs for your reference:<\/p>\n\n\n\n<p><strong>NestJS:<\/strong><\/p>\n\n\n\n<ul><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/how-to-deploy-nestjs-microservices\/\">How to Deploy NestJS Microservices to AWS Elastic Beanstalk?<\/a><\/li><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/how-to-architect-nestjs-microservices-with-aws-elastic-beanstalk\/\">How to Architect NestJS Microservices with AWS Elastic Beanstalk?<\/a><\/li><\/ul>\n\n\n\n<p><strong>ReactJS:<\/strong><\/p>\n\n\n\n<ul><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/angular-vs-react-which-one-to-choose-and-when\/\">Angular vs React: Which one to choose and when?<\/a><\/li><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/how-to-build-and-deploy-dapps-using-solidity-smart-contract-web3-js-react-js\/\">How to build and deploy dApps using Solidity Smart contract, WEB3.JS &amp; React.JS?<\/a><\/li><\/ul>\n\n\n\n<p><strong>AWS S3:<\/strong><\/p>\n\n\n\n<ul><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/how-to-etl-api-data-to-aws-s3-bucket-using-apache-airflow\/\">How to ETL API data to AWS S3 Bucket using Apache Airflow?<\/a><\/li><li><a href=\"https:\/\/www.workfall.com\/learning\/blog\/replicate-existing-s3-objects-using-s3-batch-replication\/\">How to easily replicate existing S3 objects using S3 batch replication?<\/a><\/li><\/ul>\n\n\n\n<p><strong>Keep Exploring -&gt; Keep Learning -&gt; Keep Mastering&nbsp;<\/strong><\/p>\n\n\n\n<p class=\"has-text-align-justify\">At <a href=\"https:\/\/www.workfall.com\/\">Workfall<\/a>, we strive to provide the best tech and pay opportunities to kickass coders around the world. If you\u2019re looking to work with global clients, build cutting-edge products and make big bucks doing so, give it a shot at <a href=\"https:\/\/www.workfall.com\/partner\/\">workfall.com\/partner<\/a> today!<\/p>\n\n\n\n<p><\/p>\n\n\n<style type=\"text\/css\"><\/style><section id='' \n                class='helpie-faq accordions faq-toggle open-first groupSettings-517__enabled' \n                data-collection='' \n                data-pagination='0' \n                data-search='0' \n                data-pagination-enabled='0'\n                role='region'\n                aria-label='FAQ Section'\n                aria-live='polite'><h3 class=\"collection-title\">Frequently Asked Questions:<\/h3><article class=\"accordion \"><div class='helpie-faq-row'><div class='helpie-faq-col helpie-faq-col-12' ><ul><li class=\"accordion__item \"><div class=\"accordion__header \" \r\n                id=\"accordion-header-post-2942\"\r\n                role=\"button\"\r\n                aria-expanded=\"false\"\r\n                aria-controls=\"accordion-content-post-2942\"\r\n                data-id=\"post-2942\" \r\n                data-item=\"hfaq-post-2942\" \r\n                style=\"background:transparent;\" \r\n                data-tags=\"\"\r\n                tabindex=\"0\"><div class=\"accordion__title\">Q. How do we avoid memory overload when uploading huge files?<\/div><\/div><div id=\"accordion-content-post-2942\" \r\n                class=\"accordion__body\" \r\n                role=\"region\"\r\n                aria-labelledby=\"accordion-header-post-2942\"\r\n                style=\"background:transparent;\"><p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><span style=\"font-weight: 400\">\u00a0<\/span><b>A: <\/b><span style=\"font-weight: 400\">Stream the upload instead of reading the full file into memory. Use streaming (e.g. <\/span><span style=\"font-weight: 400\">createReadStream<\/span><span style=\"font-weight: 400\">) and use multipart upload in S3 for large files to upload chunks. On the backend, use libraries (e.g. <\/span><span style=\"font-weight: 400\">aws-sdk<\/span><span style=\"font-weight: 400\"> \/ <\/span><span style=\"font-weight: 400\">@aws-sdk\/client-s3<\/span><span style=\"font-weight: 400\">) that support multipart upload. Also limit file size and concurrency, validate chunk sizes, and pipe data rather than buffering full payloads.<\/span><\/p>\n<\/div><\/li><li class=\"accordion__item \"><div class=\"accordion__header \" \r\n                id=\"accordion-header-post-2943\"\r\n                role=\"button\"\r\n                aria-expanded=\"false\"\r\n                aria-controls=\"accordion-content-post-2943\"\r\n                data-id=\"post-2943\" \r\n                data-item=\"hfaq-post-2943\" \r\n                style=\"background:transparent;\" \r\n                data-tags=\"\"\r\n                tabindex=\"0\"><div class=\"accordion__title\">Q. Should I upload directly from React (client) to S3 or route via NestJS?<\/div><\/div><div id=\"accordion-content-post-2943\" \r\n                class=\"accordion__body\" \r\n                role=\"region\"\r\n                aria-labelledby=\"accordion-header-post-2943\"\r\n                style=\"background:transparent;\"><p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><b>A: <\/b><span style=\"font-weight: 400\">A common pattern is <\/span><i><span style=\"font-weight: 400\">presigned URLs<\/span><\/i><span style=\"font-weight: 400\"> \u2014 the backend (NestJS) generates a presigned upload URL from S3 and returns it to React; React then uploads the file chunks directly to S3. This reduces load on your server and bandwidth. The backend can still verify file metadata and sign only authorized uploads.<\/span><\/p>\n<\/div><\/li><li class=\"accordion__item \"><div class=\"accordion__header \" \r\n                id=\"accordion-header-post-2944\"\r\n                role=\"button\"\r\n                aria-expanded=\"false\"\r\n                aria-controls=\"accordion-content-post-2944\"\r\n                data-id=\"post-2944\" \r\n                data-item=\"hfaq-post-2944\" \r\n                style=\"background:transparent;\" \r\n                data-tags=\"\"\r\n                tabindex=\"0\"><div class=\"accordion__title\">Q. How to resume or retry failed chunk uploads?<\/div><\/div><div id=\"accordion-content-post-2944\" \r\n                class=\"accordion__body\" \r\n                role=\"region\"\r\n                aria-labelledby=\"accordion-header-post-2944\"\r\n                style=\"background:transparent;\"><p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><span style=\"font-weight: 400\"><strong>\u00a0A:<\/strong> With S3 multipart upload, each chunk (part) has an ETag; if a part fails, you can retry that part. Track which parts succeeded vs failed (persist state). Use the S3 <\/span><span style=\"font-weight: 400\">uploadId<\/span><span style=\"font-weight: 400\"> and part numbers. Implement logic in frontend to resume from failed chunks rather than re-upload all.<\/span><\/p>\n<\/div><\/li><li class=\"accordion__item \"><div class=\"accordion__header \" \r\n                id=\"accordion-header-post-2945\"\r\n                role=\"button\"\r\n                aria-expanded=\"false\"\r\n                aria-controls=\"accordion-content-post-2945\"\r\n                data-id=\"post-2945\" \r\n                data-item=\"hfaq-post-2945\" \r\n                style=\"background:transparent;\" \r\n                data-tags=\"\"\r\n                tabindex=\"0\"><div class=\"accordion__title\">Q. Are there size or time limits I should worry about?<\/div><\/div><div id=\"accordion-content-post-2945\" \r\n                class=\"accordion__body\" \r\n                role=\"region\"\r\n                aria-labelledby=\"accordion-header-post-2945\"\r\n                style=\"background:transparent;\"><p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><span style=\"font-weight: 400\">\u00a0<\/span><b>A: <\/b><span style=\"font-weight: 400\">Yes \u2014 AWS S3 has multipart upload limits (minimum part size ~5 MB, maximum 10,000 parts, total file size up to 5 TB). Also, HTTP timeouts, network interruptions, or browser limits might cause failures. So chunking and retry logic are important. Moreover, set appropriate <\/span><span style=\"font-weight: 400\">Content-Length<\/span><span style=\"font-weight: 400\"> and <\/span><span style=\"font-weight: 400\">Content-MD5<\/span><span style=\"font-weight: 400\"> headers if you use them.<\/span><\/p>\n<\/div><\/li><li class=\"accordion__item \"><div class=\"accordion__header \" \r\n                id=\"accordion-header-post-2946\"\r\n                role=\"button\"\r\n                aria-expanded=\"false\"\r\n                aria-controls=\"accordion-content-post-2946\"\r\n                data-id=\"post-2946\" \r\n                data-item=\"hfaq-post-2946\" \r\n                style=\"background:transparent;\" \r\n                data-tags=\"\"\r\n                tabindex=\"0\"><div class=\"accordion__title\">Q. How to ensure integrity and security of the uploaded file?<\/div><\/div><div id=\"accordion-content-post-2946\" \r\n                class=\"accordion__body\" \r\n                role=\"region\"\r\n                aria-labelledby=\"accordion-header-post-2946\"\r\n                style=\"background:transparent;\"><p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span><b>A: <\/b><span style=\"font-weight: 400\">Use checksums like MD5 or SHA-256 per chunk or entire file, validate on the backend or via S3\u2019s ETag. Use HTTPS to transmit. Restrict presigned URL permissions (e.g. only PUT, limited expiry). Optionally encrypt data at rest (S3 SSE) or client-side encryption before uploading. After upload, verify file metadata (size, type) and reject unexpected files.<\/span><\/p>\n<\/div><\/li><\/ul><\/div><\/div><\/article><\/section>\n","protected":false},"excerpt":{"rendered":"<p><span class=\"rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time: <\/span> <span class=\"rt-time\">5<\/span> <span class=\"rt-label rt-postfix\">minutes<\/span><\/span> When dealing with file uploads, you must be aware that files are uploaded in buffers stored in memory and if the file is larger than the allocated memory in your VM, it may run out of memory and the application might crash. For example, if your allocated memory is 2GB, if you try to upload [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1514,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"spay_email":""},"categories":[2],"tags":[3,4,358,357,163,276,141,127,6],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v19.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog<\/title>\n<meta name=\"description\" content=\"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog\" \/>\n<meta property=\"og:description\" content=\"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/\" \/>\n<meta property=\"og:site_name\" content=\"The Workfall Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/facebook.com\/workfall\" \/>\n<meta property=\"article:published_time\" content=\"2022-11-15T12:07:11+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-09-24T10:23:31+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/ec2-18-141-20-153.ap-southeast-1.compute.amazonaws.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"628\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@workfall\" \/>\n<meta name=\"twitter:site\" content=\"@workfall\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Workfall\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#organization\",\"name\":\"Workfall - Hire #Kickass Coders On Demand\",\"url\":\"https:\/\/18.141.20.153\/learning\/blog\/\",\"sameAs\":[\"https:\/\/www.instagram.com\/workfall\/\",\"https:\/\/www.linkedin.com\/company\/workfall\/\",\"https:\/\/facebook.com\/workfall\",\"https:\/\/twitter.com\/workfall\"],\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/i1.wp.com\/18.141.20.153\/learning\/blog\/wp-content\/uploads\/2021\/10\/cropped-WF_logo.png?fit=400%2C400\",\"contentUrl\":\"https:\/\/i1.wp.com\/18.141.20.153\/learning\/blog\/wp-content\/uploads\/2021\/10\/cropped-WF_logo.png?fit=400%2C400\",\"width\":400,\"height\":400,\"caption\":\"Workfall - Hire #Kickass Coders On Demand\"},\"image\":{\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/logo\/image\/\"}},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#website\",\"url\":\"https:\/\/18.141.20.153\/learning\/blog\/\",\"name\":\"The Workfall Blog\",\"description\":\"#Tech #Remote #Jobs\",\"publisher\":{\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/18.141.20.153\/learning\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage\",\"url\":\"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png\",\"contentUrl\":\"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png\",\"width\":1200,\"height\":628,\"caption\":\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage\",\"url\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/\",\"name\":\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog\",\"isPartOf\":{\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage\"},\"datePublished\":\"2022-11-15T12:07:11+00:00\",\"dateModified\":\"2025-09-24T10:23:31+00:00\",\"description\":\"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.\",\"breadcrumb\":{\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/18.141.20.153\/learning\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?\"}]},{\"@type\":\"Article\",\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage\"},\"author\":{\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/cab8236044692bc5b27606b13167794a\"},\"headline\":\"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?\",\"datePublished\":\"2022-11-15T12:07:11+00:00\",\"dateModified\":\"2025-09-24T10:23:31+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage\"},\"wordCount\":914,\"publisher\":{\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png\",\"keywords\":[\"AWS\",\"Cloud\",\"files\",\"nestjs\",\"react\",\"reactjs\",\"s3\",\"Storage\",\"workfall\"],\"articleSection\":[\"AWS Cloud Computing\"],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/cab8236044692bc5b27606b13167794a\",\"name\":\"Workfall\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2023\/09\/avatar_user_1_1693914404-96x96.png\",\"contentUrl\":\"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2023\/09\/avatar_user_1_1693914404-96x96.png\",\"caption\":\"Workfall\"},\"sameAs\":[\"https:\/\/www.workfall.com\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog","description":"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/","og_locale":"en_US","og_type":"article","og_title":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog","og_description":"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.","og_url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/","og_site_name":"The Workfall Blog","article_publisher":"https:\/\/facebook.com\/workfall","article_published_time":"2022-11-15T12:07:11+00:00","article_modified_time":"2025-09-24T10:23:31+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/ec2-18-141-20-153.ap-southeast-1.compute.amazonaws.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png","type":"image\/png"}],"twitter_card":"summary_large_image","twitter_creator":"@workfall","twitter_site":"@workfall","twitter_misc":{"Written by":"Workfall","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Organization","@id":"https:\/\/18.141.20.153\/learning\/blog\/#organization","name":"Workfall - Hire #Kickass Coders On Demand","url":"https:\/\/18.141.20.153\/learning\/blog\/","sameAs":["https:\/\/www.instagram.com\/workfall\/","https:\/\/www.linkedin.com\/company\/workfall\/","https:\/\/facebook.com\/workfall","https:\/\/twitter.com\/workfall"],"logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/i1.wp.com\/18.141.20.153\/learning\/blog\/wp-content\/uploads\/2021\/10\/cropped-WF_logo.png?fit=400%2C400","contentUrl":"https:\/\/i1.wp.com\/18.141.20.153\/learning\/blog\/wp-content\/uploads\/2021\/10\/cropped-WF_logo.png?fit=400%2C400","width":400,"height":400,"caption":"Workfall - Hire #Kickass Coders On Demand"},"image":{"@id":"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/logo\/image\/"}},{"@type":"WebSite","@id":"https:\/\/18.141.20.153\/learning\/blog\/#website","url":"https:\/\/18.141.20.153\/learning\/blog\/","name":"The Workfall Blog","description":"#Tech #Remote #Jobs","publisher":{"@id":"https:\/\/18.141.20.153\/learning\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/18.141.20.153\/learning\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage","url":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png","contentUrl":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png","width":1200,"height":628,"caption":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?"},{"@type":"WebPage","@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage","url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/","name":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)? - The Workfall Blog","isPartOf":{"@id":"https:\/\/18.141.20.153\/learning\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage"},"datePublished":"2022-11-15T12:07:11+00:00","dateModified":"2025-09-24T10:23:31+00:00","description":"NestJS is the most rapidly growing NodeJS framework in TypeScript and ReactJS as it helps to break down the most complex of structures.","breadcrumb":{"@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/18.141.20.153\/learning\/blog\/"},{"@type":"ListItem","position":2,"name":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?"}]},{"@type":"Article","@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#article","isPartOf":{"@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage"},"author":{"@id":"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/cab8236044692bc5b27606b13167794a"},"headline":"How to upload large files (1GB and beyond) to AWS S3 using NestJS (backend) and ReactJS (frontend)?","datePublished":"2022-11-15T12:07:11+00:00","dateModified":"2025-09-24T10:23:31+00:00","mainEntityOfPage":{"@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#webpage"},"wordCount":914,"publisher":{"@id":"https:\/\/18.141.20.153\/learning\/blog\/#organization"},"image":{"@id":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-upload-large-files-1gb-and-beyond-to-aws-s3-using-nestjs-backend-and-reactjs-frontend\/#primaryimage"},"thumbnailUrl":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png","keywords":["AWS","Cloud","files","nestjs","react","reactjs","s3","Storage","workfall"],"articleSection":["AWS Cloud Computing"],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/cab8236044692bc5b27606b13167794a","name":"Workfall","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/18.141.20.153\/learning\/blog\/#\/schema\/person\/image\/","url":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2023\/09\/avatar_user_1_1693914404-96x96.png","contentUrl":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2023\/09\/avatar_user_1_1693914404-96x96.png","caption":"Workfall"},"sameAs":["https:\/\/www.workfall.com"]}]}},"jetpack_featured_media_url":"https:\/\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/11\/Cover-Images_Part2-3.png","jetpack-related-posts":[{"id":897,"url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-fetch-contents-of-json-files-stored-in-amazon-s3-using-express-js-and-aws-sdk\/","url_meta":{"origin":1513,"position":0},"title":"How to fetch contents of JSON files stored in Amazon S3 using Express.js and AWS SDK?","date":"April 5, 2022","format":false,"excerpt":"A plethora of banks employ JSON for data transfer between the bank and the client servers. With the help of Amazon S3 data lakes, the banks use the data to train AI\/ML models and perform advanced analytics. JSON is an open standard file format and data interchange format that stores\u2026","rel":"","context":"In &quot;AWS Cloud Computing&quot;","img":{"alt_text":"File Storage in Amazon S3 using Express.js & AWS SDK","src":"https:\/\/i0.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/04\/Cover-Images_Part2.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":1684,"url":"https:\/\/learning.workfall.com\/learning\/blog\/building-real-time-apps-with-nestjs-and-graphql-subscriptions\/","url_meta":{"origin":1513,"position":1},"title":"Building Real-Time Apps with NestJS and GraphQL Subscriptions","date":"April 6, 2023","format":false,"excerpt":"Real-time applications are important in several instances. Especially in a scenario whereby immediate feedback is important such as messaging apps and IoT apps. Let\u2019s imagine a case in IoT whereby a smoke detector needs to relay information to water sprinklers in a burning building. This information has to be in\u2026","rel":"","context":"In &quot;Backend Development&quot;","img":{"alt_text":"Building Real-Time Apps with NestJS and GraphQL Subscriptions","src":"https:\/\/i1.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2023\/04\/Cover-Images_Part2-1.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":1066,"url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-architect-nestjs-microservices-with-aws-elastic-beanstalk\/","url_meta":{"origin":1513,"position":2},"title":"Architect NestJS Microservices with AWS Elastic Beanstalk","date":"July 19, 2022","format":false,"excerpt":"In the AWS Cloud journey, we come across Elastic Beanstalk to be better than other services in managing the infrastructure environments effectively. On the other hand, NestJS is popular in creating efficient and scalable server-side applications, and is relatively a new option for the backend framework - it is lightweight,\u2026","rel":"","context":"In &quot;Backend Development&quot;","img":{"alt_text":"Architect NestJS Microservices with AWS Elastic Beanstalk","src":"https:\/\/i1.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2022\/07\/NestJS-Microservices-1.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":379,"url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-set-up-an-aws-cloudfront-distribution-to-speed-up-content-delivery\/","url_meta":{"origin":1513,"position":3},"title":"How to set up an AWS CloudFront distribution to speed up content delivery?","date":"November 3, 2021","format":false,"excerpt":"Do you know which of the world\u2019s largest live events and leading online video platforms (OVPs) use which services for their industry-leading security, performance, reliability, and full AWS stack integration? The answer is AWS CloudFront. Yes, you read it right! AWS CloudFront is the\u00a0 Content Delivery Network that has been\u2026","rel":"","context":"In &quot;AWS Cloud Computing&quot;","img":{"alt_text":"AWS CLoudfront - Workfall","src":"https:\/\/i2.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2021\/11\/cloudfront.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":679,"url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-set-up-a-continuous-deployment-pipeline-to-deploy-versions-of-an-application-on-aws-elastic-beanstalk-using-aws-codepipeline-part-2\/","url_meta":{"origin":1513,"position":4},"title":"How to set up a continuous deployment pipeline to deploy versions of an application on AWS Elastic Beanstalk using AWS CodePipeline (Part 2)?","date":"November 26, 2021","format":false,"excerpt":"AWS Elastic Beanstalk allows us to quickly deploy and manage applications without having to worry about the underlying infrastructure. One of its major benefits is that it reduces the complexity of management of the infrastructure without any restrictions thereby making it easy for developers to focus on just building the\u2026","rel":"","context":"In &quot;AWS Cloud Computing&quot;","img":{"alt_text":"Application on AWS Elastic Beanstalk","src":"https:\/\/i2.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2021\/11\/CoverImages_1200x628px-7.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":236,"url":"https:\/\/learning.workfall.com\/learning\/blog\/how-to-build-a-serverless-event-driven-workflow-with-aws-glue-and-amazon-eventbridge\/","url_meta":{"origin":1513,"position":5},"title":"How to build a serverless event-driven workflow with AWS Glue and Amazon EventBridge?","date":"October 28, 2021","format":false,"excerpt":"AWS Glue is basically a data processing pipeline that is composed of a crawler, jobs, and triggers. This workflow converts uploaded data files into Apache Parquet format. In this blog, we will see how we can make use of the AWS Glue event-driven workflows to demonstrate the execution of the\u2026","rel":"","context":"In &quot;AWS Cloud Computing&quot;","img":{"alt_text":"Build a Serverless Workflow with AWS Glue and Amazon EventBridge","src":"https:\/\/i2.wp.com\/learning.workfall.com\/learning\/blog\/wp-content\/uploads\/2021\/10\/Serverless-EventDriven-Workflow-1200-x-628-px.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]}],"_links":{"self":[{"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/posts\/1513"}],"collection":[{"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/comments?post=1513"}],"version-history":[{"count":5,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/posts\/1513\/revisions"}],"predecessor-version":[{"id":2948,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/posts\/1513\/revisions\/2948"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/media\/1514"}],"wp:attachment":[{"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/media?parent=1513"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/categories?post=1513"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/learning.workfall.com\/learning\/blog\/wp-json\/wp\/v2\/tags?post=1513"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}