Copilot Returns HTTP 413 Payload Too Large When Uploading: Fix
🔍 WiseChecker

Copilot Returns HTTP 413 Payload Too Large When Uploading: Fix

When you upload a file to Copilot in Microsoft 365, you may see an HTTP 413 error that stops the process. This error means the server rejected the file because its size exceeds a defined limit. The root cause is typically a restriction in the Microsoft 365 tenant configuration or a local proxy setting that caps upload size. This article explains why the error occurs and provides the exact steps to resolve it in the Microsoft 365 admin center and related tools.

Key Takeaways: Fixing HTTP 413 Errors in Copilot

  • Microsoft 365 admin center > SharePoint > File upload limit: Increase the maximum file upload size from the default 250 MB to 1 GB or higher.
  • Tenant-level SharePoint Online settings: Use PowerShell to override the default upload limit for all sites at once.
  • Local proxy or firewall inspection: Disable deep packet inspection for Microsoft 365 traffic to avoid premature rejection of large payloads.

Why Copilot Returns HTTP 413 Payload Too Large

The HTTP 413 error is an HTTP status code that means the request payload exceeds the server’s acceptable limit. In Copilot, this occurs when you upload a file that is larger than what the SharePoint Online file upload limit allows. By default, SharePoint Online restricts file uploads to 250 MB per file. Copilot relies on SharePoint storage for file processing, so any file above that threshold triggers the 413 error.

Another cause is a local proxy or firewall that inspects HTTPS traffic. Some security appliances have a default payload limit of 100 MB or 200 MB for inspection. When Copilot sends a file larger than that limit, the proxy rejects the request before it reaches Microsoft 365. The error message may appear identical to a server-side 413 error, but the fix is different.

Default SharePoint Upload Limits

SharePoint Online has a hard cap of 250 GB per file, but the default upload limit in the admin center is set to 250 MB. This setting controls the maximum file size that can be uploaded through the browser, OneDrive sync, or Copilot. The setting applies to all SharePoint sites in the tenant unless overridden at the site collection level.

How Proxy Inspection Triggers the Error

When a proxy performs deep packet inspection on HTTPS traffic, it buffers the entire request before forwarding it. If the buffer size is smaller than the file being uploaded, the proxy sends a 413 response to the client. This happens even if the Microsoft 365 server would accept the file. The error message often lacks details about the proxy, making it hard to diagnose.

Steps to Increase the SharePoint File Upload Limit

  1. Open the Microsoft 365 admin center
    Go to https://admin.microsoft.com and sign in with a Global Admin or SharePoint Admin account. In the left navigation, select Admin centers and then SharePoint.
  2. Navigate to the file upload limit setting
    In the SharePoint admin center, select Policies from the left menu. Then click Sharing in the top row. Scroll down to the File and folder links section.
  3. Increase the maximum upload size
    Under File upload limit, change the value from 250 MB to a higher number. The maximum allowed is 250 GB, but for most Copilot scenarios, setting it to 1 GB or 5 GB is sufficient. Click Save at the bottom of the page.
  4. Verify the change with a test upload
    Open a document library in any SharePoint site. Upload a file that previously caused the 413 error. If the upload succeeds, the fix is complete. If the error persists, proceed to the proxy configuration steps.

Steps to Adjust Proxy or Firewall Settings

  1. Identify the proxy or firewall appliance
    Check with your network administrator to determine the make and model of the HTTPS inspection device. Common appliances include Zscaler, Palo Alto Networks, and Cisco Umbrella.
  2. Increase the inspection payload limit
    On the appliance, locate the setting for maximum request body size or file upload limit for HTTPS inspection. Increase the value to 1 GB or higher. If the appliance allows per-URL policies, create an exception for all Microsoft 365 domains: microsoft.com, sharepoint.com, and office.com and all subdomains.
  3. Bypass inspection for Microsoft 365 traffic
    If increasing the limit is not possible, configure the proxy to bypass deep packet inspection for traffic to Microsoft 365. This prevents the proxy from buffering large uploads. After making the change, clear the proxy cache and retry the upload in Copilot.

If Copilot Still Returns HTTP 413 After the Main Fix

Copilot Returns 413 for Files Under 250 MB

If the file is smaller than 250 MB but still triggers the error, the issue is likely a per-site collection upload limit. SharePoint site owners can override the tenant default. Go to the site collection settings, select Site collection features, and activate the Large file upload feature if available. Alternatively, use PowerShell to set the upload limit for a specific site: Set-SPOTenant -MaxUploadFileSize 1048576000 sets the limit to 1 GB for all sites.

Copilot Returns 413 on Mobile or Third-Party Clients

Some mobile apps or third-party file upload tools have their own size limits. For example, the OneDrive mobile app limits uploads to 100 MB by default. Check the app settings for any file size cap and increase it if possible. For Copilot in Microsoft Teams, the upload limit is tied to the Teams file sharing limit, which is 250 MB by default. Increase this limit in the Teams admin center under Messaging policies > File sharing.

Copilot Returns 413 After a Tenant Migration

If your tenant was migrated from an on-premises SharePoint server, the upload limit may still be set to the on-premises default of 50 MB. Run the SharePoint Online Management Shell and execute Get-SPOTenant | Select MaxUploadFileSize to check the current value. If it is below 250 MB, update it with Set-SPOTenant -MaxUploadFileSize 1048576000.

SharePoint Upload Limit vs Proxy Inspection: Error Sources

Item SharePoint Upload Limit Proxy Inspection Limit
Description Server-side cap on file size in SharePoint Online Client-side cap on buffered request size in proxy appliance
Default value 250 MB Varies by appliance, often 100 MB or 200 MB
Error appears in Browser, Copilot, OneDrive sync Browser, Copilot, any HTTPS upload
Resolution location Microsoft 365 admin center > SharePoint Policies Proxy or firewall management console
Test method Upload file via SharePoint browser interface Upload file while proxy bypass is active

Copilot in Microsoft 365 relies on SharePoint for file storage and processing. The HTTP 413 error is almost always caused by the SharePoint upload limit or an intermediate proxy. After increasing the SharePoint limit to at least 1 GB and adjusting any proxy inspection rules, the error should stop. If you still see the error, check site-specific limits and client app settings. For persistent cases, run a network trace to confirm whether the rejection comes from Microsoft 365 or the proxy.