function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Custom Setting Limit Reached

I deployed updated code to an org.  When I attempt to set a custom setting I get an error that says Custom Setting Limit Reached.  I only have 6 custom settings in the org, and very few attributes in the settings.  


Has anyone else seen this?  I really thought I did not have limitations like this on custom settings.

Vincent IpVincent Ip

The only custom settings limitations i know of are documented in the help and training.



Custom Settings Limits imposes these limits on the amount of cached data and on custom settings:

• 10 MB of cached data per organization.
• 300 fields per custom setting.
• You cannot share a custom setting object or record.
• No owner is assigned when a custom setting is created, so the owner cannot be changed.



So, are you hitting that 10MB of cached data?  you can check under Setup > Administration Setup > Data Management > Storage usage and add up all the Custom Settings sizes you find in there to see if it adds up to 10MB.







Vincent - thank you for pointing me to where I can check the limits.   Unfortunately I am nowhere near any of the limits.  My current custom settings are 2K.  The interesting thing is I can add a new attribute to an existing setting but I cannot create a new one.



Vincent IpVincent Ip

Hmm..  i had previously asked Salesforce support if the Custom Settings counted towards the Custom Object limits since the Custom Settings behave very much like a Custom object.  The Salesforce Support Rep had said no...  But I wonder if the he was wrong...


if you got to the Help and Training link and search for " Editions and Limits", you can find that there are limits to the number of Custom Objects you can create in a Salesforce instance.  


For Group Edition : 50

For Developer Edition : 400

For Enterprise Edition : 200

For Unlimited Edition : 2000


You may want to check to see if the number of custom objects is anywhere near your limits for the Edition you have.  The only way I can think of getting that count quickly is going back to Setup > App Setup > Create > Objects and Copying and Pasting that list of Custom Objects into Excel and seeing how many rows you get.


If that number plus the number of Custom Settings objects you have equals one of the limits above, then perhaps Custom Settings do count as Custom Objects.


Don't know if you have any more time to spare on this problem, but if you find out anything interesting, I'd certainly love to know too.


Hope this helps.


I am off for a couple of days but I have to get this resolved.  The org where I am experiencing this problem is my packaging org.  I tend to think that the org has been corrupted somehow when I did a deploy but only Salesforce can answer the question.

Charles TairaCharles Taira
I'm running into the same exact issue. I am on Enterprise Edition and am getting limit exceeded error despite not being close to data usage limits. How did you resolve this?
Prashant Karmare 2Prashant Karmare 2
The total amount of cached data allowed for your org is the lesser of these two values:
1-10 MB
2- 1 MB multiplied by the number of full-featured user licenses in your org
For example, if your org has three full licenses, you have 3 MB of custom setting storage. If your org has 20 full licenses, you have 10 MB of storage.
 Each certified managed package can have 3 MB of custom setting storage in addition to your org’s 3-MB custom setting storage limit.

As Custom Setting are like Custom Objects. So if we treat the same here each record required 2 KB of storage space.
As an example, 500 records will require around (500 * 2 KB) 1 MB of storage.