Zoho CRM returns HTTP 500 and the UI message "Sorry something went wrong" when you click Create while saving a custom function. This is a server-side failure during the function save/compile step and usually shows as Error 500 in the browser Network tab.
What it means
The CRM backend failed while processing your custom Deluge function save request. The platform returned an internal server error (HTTP 500) instead of a normal success or validation response, so the function was not created or stored. This happens inside the CRM Functions service used from Setup > Developer Space > Functions or Setup > Automation > Actions > Functions and was reported by other users seeing Error 500 in the network tab when creating functions or automations [1][4].
Common causes
- Transient Zoho service outage or internal error on the functions/automation service [1].
- Code-level problem that crashes the server-side compiler or storage operation (invalid bytes, unsupported tokens, extremely large payload) [1][4].
- Browser or network interference: proxies, corporate firewall, or extensions blocking or truncating the request body so the server receives malformed input [4].
- Account/permissions or module configuration preventing function creation (unexpected null/mapped values or missing module metadata) that the backend did not handle gracefully [1][4].
How to fix it
- Retry from a clean client: open an Incognito/private window or another browser and try to save the function again to rule out extensions or caching.
- Test a minimal function: paste a very short, valid Deluge stub (for example a one-line comment or a single return statement) and save. If that succeeds, the problem is in your function code or size.
- Check for problematic characters and size limits: remove non-UTF8 characters, long pasted blobs, or embedded binary data. Shorten the script and avoid unusual copy/paste from rich text.
- Inspect the Network tab: capture the failing request and response, note the HTTP status, response body, request id, timestamp, and the API endpoint path. Save a HAR file if possible. This information helps support diagnose a server-side stacktrace.
- Recreate rather than edit: if edits fail repeatedly, create a new function record and paste your code in increments, saving as you go to find the exact code piece that triggers the 500.
- If the error persists after the above, open a Zoho support ticket. Attach the HAR, request id, org ID, timestamp, screenshots, and the exact function code that fails. Support can correlate logs and fix server-side issues [1][4].
When to escalate
If a minimal stub also returns HTTP 500 or the failure reproduces across browsers and networks, escalate to Zoho Support with the HAR/request id and timestamps. Those artifacts