{"record":{"id":"e901cb7176ddc3e2","repo":"vercel/next.js","slug":"server-actions-size-limit-must-be-a-valid-number-o","errorCode":null,"errorMessage":"Server Actions Size Limit must be a valid number or filesize format larger than 1MB: https://nextjs.org/docs/app/api-reference/next-config-js/serverActions#bodysizelimit","messagePattern":"Server Actions Size Limit must be a valid number or filesize format larger than 1MB: https://nextjs\\.org/docs/app/api-reference/next-config-js/serverActions#bodysizelimit","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/next/src/server/config.ts","lineNumber":1035,"sourceCode":"    result.output = 'standalone'\n  }\n\n  if (\n    typeof result.experimental?.serverActions?.bodySizeLimit !== 'undefined'\n  ) {\n    const bytes =\n      require('next/dist/compiled/bytes') as typeof import('next/dist/compiled/bytes')\n    const bodySizeLimit = result.experimental.serverActions.bodySizeLimit\n    let value: number | null\n\n    if (typeof bodySizeLimit === 'number') {\n      value = bodySizeLimit\n    } else {\n      value = bytes.parse(bodySizeLimit)\n    }\n\n    if (value === null || isNaN(value) || value < 1) {\n      throw new Error(\n        'Server Actions Size Limit must be a valid number or filesize format larger than 1MB: https://nextjs.org/docs/app/api-reference/next-config-js/serverActions#bodysizelimit'\n      )\n    }\n  }\n\n  // Throw if both Middleware and Proxy config are set.\n  if (\n    userConfig.experimental?.proxyClientMaxBodySize !== undefined &&\n    userConfig.experimental?.middlewareClientMaxBodySize !== undefined\n  ) {\n    throw new Error(\n      'Config options `experimental.proxyClientMaxBodySize` and `experimental.middlewareClientMaxBodySize` cannot be set at the same time. Please use `experimental.proxyClientMaxBodySize` instead.'\n    )\n  }\n  if (\n    userConfig.experimental?.proxyPrefetch !== undefined &&\n    userConfig.experimental?.middlewarePrefetch !== undefined\n  ) {","sourceCodeStart":1017,"sourceCodeEnd":1053,"githubUrl":"https://github.com/vercel/next.js/blob/34433fd12ee8074ea3f47af9f36255c7390d0301/packages/next/src/server/config.ts#L1017-L1053","documentation":"Error \"Server Actions Size Limit must be a valid number or filesize format larger than 1MB: https://nextjs.org/docs/app/api-reference/next-config-js/serverActions#bodysizelimit\" thrown in vercel/next.js.","triggerScenarios":"serverActions.bodySizeLimit is not a valid number or filesize string.","commonSituations":"A malformed bodySizeLimit value such as 'abc' or a size under 1MB in next.config.","solutions":["Set serverActions.bodySizeLimit to a number of bytes or a size string like '2mb' (must exceed 1MB)."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"34433fd12ee8074ea3f47af9f36255c7390d0301","analyzedAt":"2026-08-19T02:10:13.922Z","contentChangedAt":"2026-08-19T02:10:13.922Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}