Activity › Forums › Salesforce® Discussions › How to resolve heap size limit exceeded issue in Salesforce? Salesforce® Discussions How to resolve heap size limit exceeded issue in Salesforce? Posted by Anjali on August 6, 2020 at 1:29 PM How to resolve heap size limit exceeded issue in Salesforce? Deepak replied 5 years, 9 months ago 2 Members · 1 Reply 1 Reply Deepak Member August 6, 2020 at 2:22 PM Look for heap size in debug logs. If heap size is approaching the limit, investigate it and refactor the code. Use the ‘Transient’ keyword with variables. Use Limit methods. Reduce heap size during runtime by removing items from the collection as you iterate over it. Use SOQL for loops. Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me