Skip to main content
Question

Plugin failing with “RuntimeError: memory access out of bounds” in WebAssembly

  • August 27, 2025
  • 3 replies
  • 187 views

Email_Love

Hi all,

 

We’ve built a Figma plugin that converts frames into MJML/HTML using a WebAssembly module. On some machines the plugin works fine, but on others (mostly Macs with Apple Silicon) it crashes part-way through with this error:

 

 

What happens:

  • Some components (usually text) render successfully.

  • As soon as the plugin hits a problematic component, it throws the error and everything after that fails to generate.

  • The issue isn’t consistent — some users/accounts never see it, while others hit it frequently.

 

What we’ve tried:

  • Clearing Figma caches and reinstalling the desktop app.

  • Testing on multiple accounts and machines.

  • Disabling Cloudflare/WAF rules on our API.

  • The problem still persists.

 

Impact:

Users can’t reliably export frames — exports stop midway and produce incomplete output.

 

Suspected cause:

It looks like the WASM module is running out of memory or hitting a bug with certain text inputs. The error consistently comes from the WASM runtime.

 

Has anyone run into this before with plugins that use WASM?

  • Are there known memory limits in Figma’s plugin environment that could explain this?

  • Any best practices for handling text safely to avoid these crashes?

  • Would recompiling the WASM with different memory settings help?

 

Any guidance would be greatly appreciated — we’d love to make the plugin more reliable for users across all machines.

 

Thanks!

3 replies

Gayani_S
Figmate
  • Community Support
  • September 1, 2025

Hi ​@Email_Love, thanks so much for taking the time to share all these details about the issue and what you’ve already tried. I can see you’ve also reached out to our Support team (#1485544). Just to confirm, are you the creator of the plugin?

I’ve shared your forum post with our Support team as well, since the extra information you’ve included here will help them in investigating this further. The best next step is to continue following up on your support ticket, and they’ll be able to work with you directly to dig deeper. 

 

Thank you, 

Gayani 


Kathy Toufighi

Did we get this issue resolved! I am having the same issue and tried clearing cache as it was proposed by another forum. 

Error:

vendor-core-22161ccd…fde64a.min.js.br:58 MobileFileViewer: failed to initialize RuntimeError: memory access out of bounds


Email_Love
  • Author
  • New Member
  • January 19, 2026

For us, it was due to the way the project was built. A new typescript loader library was used to build the plugin for faster build process but it seems to have caused overhead for systems with lower memory. Now the loader library has been changed to a native one which seems to be working properly for devices with lower memory too.