# Can't package for android (rungradle.bat error)

**URL:** <https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871>\
**Category:** Mobile\
**Tags:** error, gradle, unreal-engine, question\
**Created:** [January 27, 2021, 6:10pm UTC](https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871 "2021-01-27T18:10:54Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![AristideEXE](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AristideEXE](https://forums.unrealengine.com/u/AristideEXE)\
**Post date:** [January 27, 2021, 6:10pm UTC](https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871/1 "2021-01-27T18:10:54Z")

</div>

Hello since I checked the box Generate bundle (AAB) in the Android settings my project doesn’t want to package and it gives me this error :

 ![328236-capture-output-log.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/7/5/f75e77cc408eaf7b085a1b0cf26742b280d05003.png)

I already tried a lot of things like delete the Intermediate file and the Saved File, and the NVPACK/android-sdk-windows/tools/android.bat doesn’t make anything …  
When this box wasn’t check it didn’t have problems but I need to generate .aab files …  
Do you know how to fix this error ?

---

<div class="post-metadata">

**Author:** ![georgerecursive](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@georgerecursive](https://forums.unrealengine.com/u/georgerecursive)\
**Post date:** [April 19, 2021, 11:07am UTC](https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871/2 "2021-04-19T11:07:36Z")

</div>

Hi THere, Did you find a solution for this error message? I’m in the same shoe and any input would be highly appreciated, Many thanks!

---

<div class="post-metadata">

**Author:** ![Samush](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Samush](https://forums.unrealengine.com/u/Samush)\
**Post date:** [April 19, 2021, 11:43pm UTC](https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871/3 "2021-04-19T23:43:48Z")

</div>

Sure, you have to delete that file and in some cases the entire “gradle” and even all the “Android” and “Intermediate” folder, it worked for me. Sometimes I just delete the .bat file and it works but sometimes I have to delete all the “Intermediate” folder and subfolders and let ue4 redo it again…  
Just try deleting .bat, package, if it doesn’t work, delete “gradle” folder, then “Android” and the, if it doesn’st works, “Intermediate”.

Good luck! Hope it works for you.

---

<div class="post-metadata">

**Author:** ![Julian094](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Julian094](https://forums.unrealengine.com/u/Julian094)\
**Post date:** [March 25, 2022, 11:01pm UTC](https://forums.unrealengine.com/t/cant-package-for-android-rungradle-bat-error/477871/4 "2022-03-25T23:01:39Z")

</div>

Hi, Did you find a solution for this error? I coud not find any solution for this. Thanks!
