ScriptManager Component

The ScriptManager component is a migration stub that exists solely for markup compatibility when migrating from ASP.NET Web Forms. It renders no visible output.

Migration Note

In Web Forms, ScriptManager was required on every page that used AJAX features (UpdatePanel, Timer, etc.). It managed JavaScript resources, partial rendering, and web service proxies.

In Blazor, these responsibilities are handled by the framework itself:

  • Partial rendering — Blazor's diff-based rendering handles this automatically
  • Script management — Use <script> tags or JS interop
  • Page methods — Use Blazor component methods or API controllers
  • Globalization/Localization — Use .NET localization middleware

You can safely remove <ScriptManager> after migration is complete, or leave it in place — it has no effect on rendering or performance.


Usage (renders nothing)

The component below is present on this page but produces no HTML output:

↑ A ScriptManager is rendered above this line. Inspect the page source to confirm it produces no HTML.

<ScriptManager EnablePartialRendering="true" ScriptMode="ScriptMode.Auto" />

Supported Properties (for migration compatibility)

Property Type Default Notes
EnablePartialRenderingboolfalseNo effect in Blazor
EnablePageMethodsboolfalseNo effect in Blazor
ScriptModeScriptModeAutoNo effect in Blazor
AsyncPostBackTimeoutint90No effect in Blazor
EnableCdnboolfalseNo effect in Blazor
EnableScriptGlobalizationboolfalseNo effect in Blazor
EnableScriptLocalizationboolfalseNo effect in Blazor

Web Forms Equivalent

<!-- Web Forms — required on every AJAX-enabled page -->
<asp:ScriptManager ID="ScriptManager1" runat="server"
    EnablePartialRendering="true"
    EnablePageMethods="true"
    AsyncPostBackTimeout="90" />