# Why do I get the error “JavaScript heap out of memory” during deployment? The error `FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory` means your Node.js build process exceeded the available memory during deployment. To resolve this issue, increase the Node.js memory limit. Go to [the **Apps** section of the DigitalOcean Control Panel](https://cloud.digitalocean.com/apps), click your app, and then click the **Settings** tab. Under the **Environment Variables** heading, click **Edit**, and then in the **Keys** field, type `NODE_OPTIONS`. In the **Values** field, type `--max-old-space-size=4096`. Then, redeploy your app. If your build continues to fail with an out of memory error, [try optimizing your build](https://docs.digitalocean.com/support/why-is-my-app-platform-build-or-deployment-failing-with-an-out-of-memory-error/index.html.md). ## Related Topics [How do I fix the error "Record is managed by an App on this account, and cannot be deleted"?](https://docs.digitalocean.com/support/how-do-i-fix-the-error-record-is-managed-by-an-app-on-this-account-and-cannot-be-deleted/index.html.md): Use the app’s Settings tab to remove domains associated with App Platform apps. [How do I fix a "permission denied for schema public" error in my dev database?](https://docs.digitalocean.com/support/how-do-i-fix-a-permission-denied-for-schema-public-error-in-my-dev-database/index.html.md): Delete the existing dev database and create a new one. Then make sure that the app deployment completes successfully. [Why do I get the error "Domain Already Exists" when trying to add a domain to an app in another account?](https://docs.digitalocean.com/support/why-do-i-get-the-error-domain-already-exists-when-trying-to-add-a-domain-to-an-app-in-another-account/index.html.md): You cannot add the same domain name to multiple apps or split an app and domain name across more than one account.