Headless Sitefinity with React: moving to the renderer

With Sitefinity’s renderer approach, React runs headless in front of the CMS: Sitefinity provides content and page structure, a Next.js application renders the pages. For an existing project this means moving page by page, and this is exactly where Web Components help, because they run in both worlds. In this article I explain how the renderer works according to the Progress documentation, where the limits of a gradual move are and how React and existing StencilJS components fit together. I am currently building this move for an energy provider’s websites; as a first step we are converting every page to React.

How does the renderer work?

In this model Sitefinity separates presentation from the CMS. The presentation layer is either the ASP.NET Core Renderer or the Next.js Renderer. Renderer and CMS talk to each other through the Page Layout Service, using REST. According to Progress this also makes it easier to upgrade the backend, because presentation runs separately.

For the ASP.NET Core Renderer the documentation describes the flow in detail: the renderer forwards a page request to Sitefinity, and the CMS checks whether it is a renderer page. If it is, Sitefinity returns a JSON file with the page structure, and the renderer assembles the page with its own templates and widgets. For MVC pages Sitefinity renders the HTML itself and returns it to the renderer, which serves it as it is.

The renderer is a proxy at the same time: whatever it does not answer itself is forwarded to Sitefinity. With the ASP.NET Core Renderer its own resources live under the sfrenderer path, and each forwarded request carries the header SF-RENDERER-PROXY=true, from which the CMS knows that it came through the renderer. For visitors and editors it stays one domain, no matter which application answers a request.

What changes for development?

For React developers the Next.js Renderer is a regular Next.js application with an SDK for Sitefinity. As prerequisites the documentation lists an LTS version of Node.js and a minimum version of Sitefinity; the exact versions are in the renderer’s setup guide. The SF_CMS_URL variable tells the application where to forward all requests that are not pages and where to send its API calls.

Widgets become React components. A widget consists of a .tsx component and an entity class. The entity describes the fields from which Sitefinity builds the dialog for editors:

import { WidgetEntity } from '@progress/sitefinity-widget-designers-sdk';

@WidgetEntity('HelloWorld', 'Hello world')
export class HelloWorldEntity {
    Content: string | null = null;
}

A registry maps each widget to its component, and a flag decides whether it renders on the server or in the browser. One detail that is easy to miss: the widget needs the attributes from the SDK function htmlAttributes(props) on its root element, so that the editor recognises it as a widget and it is visible in edit mode.

Templates are created either in the Sitefinity backend or programmatically through layout files. To make a template a Next.js template, it has to be based on another programmatically created Next.js template or on the default Next.js template. Editors get a WYSIWYG editor that shows the page as it will appear on the front end. It requires a dedicated Next.js template for the page.

Why can pages only be moved one at a time?

The Progress documentation describes a hybrid approach: move one page at a time from MVC or Web Forms to the renderer, and with the page all widgets on it. There is no mixing on the same page. In the documentation’s words, ASP.NET Core or Next.js widgets cannot be rendered in MVC or Web Forms pages, and vice versa.

For running both side by side, the two renderers differ. The ASP.NET Core Renderer proxies MVC pages automatically. With the Next.js Renderer, all pages still built with MVC or Web Forms have to be submitted explicitly, for example through the SF_WHITELISTED_PATHS variable with a list of paths. This is how the documentation enables a page by page migration. To me this also makes the list a useful overview during a move of which pages are still on the old stack.

For the move itself Progress provides the Sitefinity CLI. It migrates the content and structure of page templates and pages, built-in widgets where an equivalent exists for the new renderers, forms and, with a separate command, form responses, and it requires Sitefinity 15.3 or later. It does not migrate custom widgets or custom code; those have to be implemented again. In a project with many custom widgets that is a large part of the work.

How do the existing Web Components fit in?

This is where a decision made long before the renderer pays off. The websites’ front end consists of Web Components built with StencilJS. In the MVC pages they appear as tags in the Razor views. To React they are HTML elements as well. A React widget can therefore use the same component that used to sit in Razor. Presentation, behaviour and accessibility come from the same library, whichever stack a page is on at the moment.

A new React widget can thereby become a thin layer: it reads the entity’s fields and passes them on to the Web Component. The real work stays in the component, which is developed and checked in Storybook.

What do you need to watch for with custom elements in React?

For a long time the combination was awkward, because React treated unknown props as attributes rather than properties. React 19 adds full support for custom elements. In the browser React assigns a prop as a property if the element has a property with that name, otherwise as an attribute. During server rendering only primitive values such as strings, numbers and true become attributes. Objects, functions and false are omitted there.

For a Next.js application that renders on the server this matters: without a wrapper, a component that expects data as an object does not get it in the first HTML. It is therefore worth designing component interfaces so that everything that has to be visible on first render arrives through simple attributes or slots.

React listens to custom events with the on prefix directly in JSX. Event names are case-sensitive and may contain dashes:

<my-element onsay-hi={console.log}></my-element>

Stencil also provides its own output target for React, which generates a React wrapper component for each component, with bindings for events and properties. The documentation lists React 17 and later and support for server-side rendering with frameworks such as Next.js. For rendering Stencil components on the server there is also the dist-hydrate-script output target. By default it outputs components with Shadow DOM as Declarative Shadow DOM.

What I take away from the move

  • The renderer separates presentation and CMS cleanly, and as a proxy it keeps both under one domain.
  • Pages move one at a time, always with all widgets of a page. With the Next.js Renderer the list of submitted legacy pages shows what is left.
  • Custom widgets have to be rebuilt, the Sitefinity CLI does not migrate them.
  • Web Components make the transition easier, because the same component runs in Razor and in React.
  • In React 19 server rendering, only primitive values become attributes. That belongs in the design of component interfaces.

All articles

Legal Notice

DIGITALPASSION Ltd.

Tassou Papadopoulou 16
House 2
8270 Tremithousa, Cyprus
Email:
info@kevin-damiani.de
Register Number:
HE 454538
Represented by:
Kevin Damiani
VAT ID:
CY60039739L

IT Liability Insurance

exali AG
Franz-Kobinger-Str. 9, 86157 Augsburg

Dispute Resolution

We are not willing or obliged to participate in dispute resolution proceedings before a consumer arbitration board.

Liability for Content

As a service provider, we are responsible for our own content on these pages in accordance with general laws. However, liability is only possible from the time of knowledge of a specific infringement.

Copyright

The content and works created by the site operators on these pages are subject to German copyright law. Downloads and copies of this site are only permitted for private, non-commercial use.

Privacy Policy

The protection of your personal data is important to us. This privacy policy informs you about the processing of personal data on this website and in the iPad app DrawBook (see DrawBook).

Data Controller

Responsible for data processing on this website and in the DrawBook app is:

DIGITALPASSION Ltd.
Tassou Papadopoulou 16, House 2, 8270 Tremithousa, Cyprus
Email: info@kevin-damiani.de

Hosting

This website runs on our own server at Hostinger International Limited, 61 Lordou Vironos Street, 6023 Larnaca, Cyprus, in the data center in Frankfurt am Main; Hostinger processes the data on our behalf (Art. 28 GDPR). To deliver the page, our web server processes your IP address, the time, the page viewed and the referring page, and your browser identifier. It keeps no access log; it passes page views on only in shortened form for web analytics (see Web Analytics). If it cannot deliver the page, it writes an error line with the time, the page viewed and the referring page (both without parameters after the "?"), your browser identifier and your IP address shortened to the first 24 bits (IPv4) or 48 bits (IPv6). These lines are overwritten continuously: we keep at most 30 MB of them, and older ones are dropped as new ones arrive, so there is no period in days. In addition, Hostinger backs up the whole server once a week in a data center in Lithuania and keeps the two most recent backups. The legal basis is our legitimate interest in providing the website securely and reliably (Art. 6(1)(f) GDPR). You are not obliged to provide this data; without the transmission of your IP address, however, the website cannot be delivered.

Cookies and local storage

This website does not set any cookies and stores nothing in your browser's storage (neither localStorage nor sessionStorage). No identifiers for recognizing you are stored on your device, and there are no entries from third parties; how we count visits is described under Web Analytics.

Web Analytics

So that we know how often this website is visited, where visitors come from and which language version they read, our web server (see Hosting) evaluates each successfully loaded page view. No script runs in your browser for this, no cookies are set and nothing is read from or stored on your device. If your browser sends the Global Privacy Control or Do Not Track signal, the page view is not counted. It shortens the IP address (for IPv4 without the last byte, for IPv6 only the first 48 bits) and passes it on, together with the time, the page viewed, the referring page (both without parameters after the "?"), the browser identifier and the name of this website, to our own analytics software Umami, which runs on the same server (see Hosting). It does not pass on other details of the request, such as the language setting, and it writes no log in doing so. Umami stores neither the IP address nor the browser identifier, but derives browser, operating system and device type as well as country, region and city from them, plus page, referrer and time. It groups page views into visits using an identifier calculated from the shortened address, the browser identifier and a secret key that changes every day; page views from different days therefore cannot be linked. Umami does not count page views from recognizable bots. Umami deletes the data after 363 days. Backups are stored encrypted on a server we run ourselves in Cyprus and mirrored from there to storage in Germany that we also run ourselves; no copy is older than 400 days. We do not pass the data on to third parties. The legal basis is our legitimate interest in knowing the reach of the website and improving it (Art. 6(1)(f) GDPR); you can object under Art. 21 GDPR (see Your Rights), most easily by turning on Global Privacy Control or Do Not Track in your browser.

Fonts

This website uses locally hosted fonts (self-hosting). No connections are made to external servers such as Google Fonts.

Contact

If you contact us by email, your information will be stored for processing the request and for possible follow-up questions. We receive and store emails with our processor Fastmail Pty Ltd, Australia; there is no adequacy decision of the European Commission for Australia, so the transfer is based on the EU Standard Contractual Clauses in Fastmail's data processing agreement (available at fastmail.com/policies/dpa). Beyond that, we will not share this data without your consent. The legal basis is Art. 6(1)(b) GDPR if your request aims at concluding or performing a contract, otherwise our legitimate interest in answering it (Art. 6(1)(f) GDPR). We delete the data once the request has been dealt with, unless statutory retention obligations apply. Providing your information is voluntary; without an email address we cannot reply to you.

DrawBook

DrawBook is a free note-taking and drawing app for iPad that DIGITALPASSION Ltd. offers on the App Store. We run no server for DrawBook: we receive neither your notebooks nor your AI requests or API keys. The app needs no DrawBook account, and it contains no analytics, no advertising and no tracking.

Notebooks, drawings, typed text and imported PDF pages stay on your device, in the app's protected storage, and are excluded from automatic device backups. If you export or share something, you decide where the copy goes. Deleting the app also deletes its notebooks.

You can also use the AI chat "Drawing AI". It only works with your own API key for OpenRouter, Ollama Cloud, Anthropic (Claude) or OpenAI; the app stores the key in your device's Keychain. Nothing is sent until you tap "Activate" under "AI configuration" and confirm the dialog that follows. This consent applies to the selected provider, model and image setting, and the app checks it before and after every request. "Deactivate" withdraws it, and "Remove Saved API Key" deletes the key.

Requests go over HTTPS directly from your device to the selected provider (openrouter.ai, ollama.com, api.anthropic.com or api.openai.com). They contain your prompt, the recent conversation and a summary of the page. When the AI reads the page, editable objects such as typed text and shapes are added, along with handwriting recognized on your device and the coordinates of your strokes. If "Send Page as Image to AI" is on (off by default), the AI can also request an image of the page, including an imported PDF background. OpenRouter may forward a request to the actual model provider.

DIGITALPASSION does not receive this data. The app transfers it only with your consent (Art. 6(1)(a) GDPR) to the provider, which processes it under its own terms as an independent controller. How long the provider keeps it is set by its terms; you exercise your rights regarding data it has already received with the provider. DrawBook keeps the chat history only in memory, and "New thread" clears it. We answer privacy questions about DrawBook at info@kevin-damiani.de.

Your Rights

You have the right to:

  • Information about your stored data (Art. 15 GDPR)
  • Correction of inaccurate data (Art. 16 GDPR)
  • Deletion of your data (Art. 17 GDPR)
  • Restriction of processing (Art. 18 GDPR)
  • Data portability, where processing is based on consent or a contract and carried out by automated means (Art. 20 GDPR)
  • Withdrawal of consent given, at any time and with effect for the future (Art. 7(3) GDPR)

In case of complaints, you can contact the responsible data protection supervisory authority (Art. 77 GDPR).

Right to object

Where we process data on the basis of legitimate interests (Art. 6(1)(f) GDPR), you can object at any time on grounds relating to your particular situation (Art. 21 GDPR). An informal email is sufficient.

SSL Encryption

This website uses SSL encryption for security reasons. You can recognize an encrypted connection by the lock symbol in your browser's address bar.

Changes

We reserve the right to adapt this privacy policy to changes in the law or in the service.

Last updated: November 2026