- Home /
Do Unity's WebGL builds have a memory leak?
Both wasm and asm builds have JVMs that slowly increase in size. This is most noticeable for asm builds that require a memory declaration at build time. If I leave my application running for an hour, it will run out of memory and present the message, "Out of memory. If you are the developer of this content, try allocating more memory to your WebGL build in the WebGL player settings." I have allocated 512MB to the application as a stop gap solution, but it still will eventually hit that limit. The application begins with a JVM size under 40MB.
I have profiled my code within the Editor using the Profiler and there is no observable memory leak.
Has anyone ever observed this in their builds? Is there any additional information I can provide?
I suggest profiling memory on WebGL and on a different platform, like Android or iOS using IL2CPP as Scripting Backend.
Your answer
Follow this Question
Related Questions
Distribute terrain in zones 3 Answers
GL build won't run on Chrome 1 Answer
String coming as null from Unity to HTML WebGL 0 Answers
Cloud Built WebGL Stopped working 0 Answers
I can't get browser to Webgl communciation working 2 Answers