Add Data Widget Upload Limit

309
5
07-24-2025 01:27 PM
Labels (2)
JaredPilbeam2
MVP Alum

The limit on the Add Data Widget is surprisingly small. It doesn't tell you the limit either. It won't even take a 46KB .csv file. That almost makes it kind of useless. I'm here wondering if I can manipulate the widget to increase the limit? Or can you even customize out-of-the-box widgets? 

EDIT: The actual error/warning reads:

The number of records in <file> exceeds the maximum threshold.

 

0 Kudos
5 Replies
VenkataKondepati
Occasional Contributor

Hi @JaredPilbeam2,
The Add Data widget has a small, hardcoded upload limit — even small CSVs get blocked. You can’t change it in standard Experience Builder, but if you’re using the Developer Edition, you could tweak the widget code to lift that limit. Otherwise, best workaround is uploading the CSV as a hosted layer and pulling it in that way.

0 Kudos
JaredPilbeam2
MVP Alum

@VenkataKondepati 
Yes, my question is referring to the dev edition. (1) I'm not sure how to get the source file of an out-of-the-box widget such as the Add Data widget. (2) I then was wondering where to tweak it.

0 Kudos
VenkataKondepati
Occasional Contributor

Yes, with the Dev Edition, you definitely have the flexibility to customize out-of-the-box widgets like Add Data.

  1. First, locate the widget source – usually under:
    client/your-app/widgets/common/add-data

  2. Look inside files like widget.tsx for upload validation logic. There’s typically a maxUploadSize or similar check you can tweak. Just bump that limit up as needed.

  3. After changes, don’t forget to rebuild your app (npm run build:dev) so it reflects in the UI.

0 Kudos
JaredPilbeam2
MVP Alum

I found a few lines referring to the file sizes allowed in the data-file-upload.tsx file. 10MB is the limit for a .csv file. That can't be what's stopping me.

const MaxFileSize: { [key in SupportedFileTypes]: number /** bytes */ } = {
  [SupportedFileTypes.CSV]: 10485760,
  [SupportedFileTypes.GeoJson]: 10485760,
  [SupportedFileTypes.Shapefile]: 2097152,
  // KML size limitaion: https://doc.arcgis.com/en/arcgis-online/reference/kml.htm
  [SupportedFileTypes.KML]: 10485760,
  [SupportedFileTypes.GPX]: 10485760
}

 So, I looked to the Exceeded Max Records error in the same file, which is apparently 1000. But, I haven't seen where to change it yet.

0 Kudos
VenkataKondepati
Occasional Contributor

You're right to dig into data-file-upload.tsx. The 10MB size limit isn’t the issue here — your 46KB CSV is well within range. The real problem is the record count limit, which is capped at 1,000 records in the default Experience Builder Add Data widget.

What’s Actually Happening

In the widget’s logic, there’s a check like this:

if (features.length > 1000) {
  throw new Error('Exceeded Max Records')
}

 

So even if your file is tiny, if it has over 1,000 rows, it’ll throw that error.

What You Can Do
Since you’re using Developer Edition, you can:

Navigate to the data-file-upload.tsx file.

Locate the line that throws the “Exceeded Max Records” error.

Increase the threshold (e.g., 5000 or more based on your needs).

Rebuild your app using:

npm run build:dev

 

Restart Experience Builder and test.

Please check the link below.
https://doc.arcgis.com/en/experience-builder/11.2/configure-widgets/add-data-widget.htm?utm_source=c...



0 Kudos