Salesforce Dictionary - Free Salesforce GlossarySalesforce Dictionary
Full Salesforce Functions entry
How-to guide

How to set up Salesforce Functions in Salesforce

Salesforce Functions WAS an elastic-compute service for running custom logic in Java / JavaScript / TypeScript outside the standard Apex governor limits. It was RETIRED on January 31, 2025. Existing Functions deployments stopped running on that date; new development should use Apex (for in-platform logic), External Services (for REST callouts), or Heroku (for elastic compute).

By Dipojjal Chakrabarti · Editor, Salesforce DictionaryLast updated Apr 20, 2026

Salesforce Functions WAS an elastic-compute service for running custom logic in Java / JavaScript / TypeScript outside the standard Apex governor limits. It was RETIRED on January 31, 2025. Existing Functions deployments stopped running on that date; new development should use Apex (for in-platform logic), External Services (for REST callouts), or Heroku (for elastic compute).

  1. Recognize that Salesforce Functions is retired

    As of January 31, 2025, Salesforce Functions no longer runs. Existing deployments are inactive.

  2. Identify what your Functions did

    Audit code in your sfdx project's functions/ directory. Each function had a specific purpose — bulk data processing, external API integration, complex computation.

  3. Pick the right replacement based on use case

    Bulk data processing → Apex Batch / Queueable. External API → External Services + Apex callouts. Heavy compute → Heroku app called via REST. Long-running jobs → Heroku or External Service with async pattern.

  4. Migrate function logic to the chosen replacement

    Re-implement in Apex / Heroku / external service. Update calling code to point at new endpoints / Apex methods.

  5. Test thoroughly in a sandbox

    New approach has different behavior, latency, error handling — run end-to-end tests before production cutover.

  6. Decommission the old Functions configuration

    Remove from sfdx project; clean up any references in calling code.

Key options
Replacement: Apex Batch / Queueableremember

For Salesforce-internal heavy logic.

Replacement: External Servicesremember

For declarative external API calls.

Replacement: Herokuremember

For elastic compute outside Salesforce.

Replacement: Workato / Mulesoftremember

For complex integration workflows.

Gotchas
  • Salesforce Functions retired January 31, 2025. Documentation referencing it is outdated. Don't try to deploy new Functions — they don't run.
  • Migration paths vary by use case. There's no one-to-one replacement; pick based on what the function actually did. Heroku is closest in spirit but has its own deployment model.
  • Apex governor limits apply to Apex replacements. Functions code that relied on bypassing governor limits (heavy compute, large data) needs Heroku — Apex won't fit.

See the full Salesforce Functions entry

Salesforce Functions includes the definition, worked example, deep dive, related terms, and a quiz.