Back to Blog

    Engineering

    SPFx: Heft is the default, React 18 is still in preview

    Which React version does SPFx support? The current state of Heft, the new CLI and React 18 for production SharePoint projects.

    June 3, 20262 min read
    Marcel Haas

    Marcel Haas

    Solution Architect, CEO

    marcel.haas@cnext.ch
    CNEXT Desk Setup
    In this article

    As of September 2026. SharePoint Framework (SPFx) teams need to keep two changes apart: the Heft toolchain is already the default for new projects, whereas React 18 is only available in the SPFx 1.24 preview. If you maintain a production solution, do not raise the React version on speculation.

    React 18: only in the SPFx 1.24 preview

    Microsoft's SPFx compatibility table still lists React 17.0.1 for SPFx 1.20 to 1.23.2. The SPFx 1.24 release notes describe React 18 as a feature of a preview release. Microsoft does not recommend this preview for production environments.

    This has a practical consequence: an existing web part on SPFx 1.20 or 1.22 does not need to switch from ReactDOM.render() to createRoot(). The often-cited React 18 migration step belongs in a deliberate test with an SPFx version that is actually compatible. Whenever you upgrade, check the exact React version in Microsoft's table and install it without automatic version jumps. Microsoft documents --save-exact for this.

    Heft: the switch has already happened

    SPFx 1.22 introduced Heft as the default build tool for newly generated projects. Existing Gulp projects could initially keep building with Gulp after upgrading to 1.22. Microsoft describes a gradual transition: new projects should use Heft, while older solutions need to review their own build customisations before migrating. Webpack remains part of the toolchain.

    For a team with several SPFx solutions, the right order is:

    1. 1Take inventory: Record the SPFx, Node, React and toolchain version of each solution.
    2. 2Check security and maintenance status: Refer to the current supported SPFx version and the release notes.
    3. 3Test Heft separately: Choose a representative project with its own Gulp tasks, webpack customisations and CI pipeline.
    4. 4Trial React 18 separately: Only in a test environment with the documented SPFx 1.24 preview; do not derive a production migration from an announcement.

    New CLI: useful, but tied to versions

    Microsoft offers an SPFx CLI for generating and building projects. Before using it, check the supported Node and SPFx versions as well as your existing customisations, packages and deployment pipeline.

    What development teams should do now

    Plan the Heft migration according to each project's actual state. Keep production React dependencies at the version Microsoft supports. Test React 18 in isolation, document blockers and wait for an SPFx version supported for production before you switch client solutions. This avoids a framework mix that Microsoft's compatibility table does not cover.

    SharePointMicrosoft 365Agentic EngineeringBest Practices
    Teilen:

    AI tools may have supported the creation of this article. CNEXT is responsible for the published content. Product features and prices can change; check the linked primary sources for current details.

    Marcel Haas

    Marcel Haas

    Solution Architect, CEO

    6x Microsoft Applied Skills

    Discuss SPFx migration with CNEXT

    We review the state of your SPFx solutions with you and plan Heft and React updates.