PeakSWC.RemoteWebView 10.0.15.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package PeakSWC.RemoteWebView --version 10.0.15.1
                    
NuGet\Install-Package PeakSWC.RemoteWebView -Version 10.0.15.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="PeakSWC.RemoteWebView" Version="10.0.15.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="PeakSWC.RemoteWebView" Version="10.0.15.1" />
                    
Directory.Packages.props
<PackageReference Include="PeakSWC.RemoteWebView" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add PeakSWC.RemoteWebView --version 10.0.15.1
                    
#r "nuget: PeakSWC.RemoteWebView, 10.0.15.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package PeakSWC.RemoteWebView@10.0.15.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=PeakSWC.RemoteWebView&version=10.0.15.1
                    
Install as a Cake Addin
#tool nuget:?package=PeakSWC.RemoteWebView&version=10.0.15.1
                    
Install as a Cake Tool

RemoteBlazorWebView.Wpf.BlazorWebView

RemoteBlazorWebView.Wpf.BlazorWebView is a powerful control based on the .NET 9 Blazor WebView Control for WPF applications. It allows you to interact with the user interface of a program developed using the BlazorWebView WPF control through a web browser by leveraging a cloud-based server.

The RemoteBlazorWebView.Wpf.BlazorWebView control facilitates remote interaction with your application's user interface by setting up a server (RemoteWebViewService) in the cloud and connecting your browser to it.

As a drop-in replacement for the Microsoft.AspNetCore.Components.WebView.Wpf.BlazorWebView control, RemoteBlazorWebView.Wpf requires only minimal changes to your existing application to enable remote control capabilities. This makes it an efficient and convenient solution for extending your application's functionality.

RemoteBlazorWebView.WindowsForms.BlazorWebView

RemoteBlazorWebView.WindowsForms.BlazorWebView is a robust control built on the .NET 9 Blazor WebView WinForms Control, designed for Windows Forms applications. It allows you to engage with the user interface of a program created using the BlazorWebView WinForms control through a web browser, utilizing a cloud-based server.

The RemoteBlazorWebView.WindowsForms.BlazorWebView control enables remote interaction with your application's user interface by establishing a server (RemoteWebViewService) in the cloud and directing your browser to connect with it.

As a seamless replacement for the Microsoft.AspNetCore.Components.WebView.WindowsForms.BlazorWebView control, RemoteBlazorWebView.WindowsForms.BlazorWebView necessitates only minimal adjustments to your current application to empower remote control capabilities. This makes it an effective and user-friendly option for enhancing your application's features.

Demo Video

RemoteBlazorWebView

Usage instructions

You do not need to build this repo unless you want to customize the RemoteWebViewService. Run the following command to install the RemoteWebViewService

dotnet tool update -g PeakSWC.RemoteWebViewService --version 9.*-* 

Switching between local and remote

Mark the window with [RemoteBlazor(nameof(MyBlazorWebView), ...)] and call the generated InitializeRemoteBlazor() after InitializeComponent(); see the source generator's README.

Sharing control (owner, remote user, viewers)

A session can be shared between the person at the machine and a remote user, with control handed back and forth.

Roles. A session supports exactly these participants:

Role How they join What they can do
Owner (one) The app's own window shows the controlling page /app/<id>?role=owner (BlazorWebView.NavigateToUrl). Starts in control. Can give control to the remote user and can always take it back.
Remote user (one) Opens the read-only link /mirror/<id> (requires EnableMirrors). The remote user is the first non-owner connection in the session. Watches until the owner gives control; then drives the app and can give control back. Gets the remote user's end of the voice call when voice is on.
Viewers (any number) Open the same /mirror/<id> link after the remote user. Read-only. They are never given control, cannot take it, and have no voice.

Only one connection controls the app at a time; the relay ignores input from everyone else, and control is never given to a second remote user. If the remote user leaves, the next-oldest viewer becomes the remote user. If the connection in control closes, control returns to the owner while the owner is connected; otherwise the session ends.

Supervised or unattended. By default a session is supervised: the owner starts in control and decides when to give it. Add &control=remote to the owner's page address (/app/<id>?role=owner&control=remote) for an unattended session: the remote user is given control as soon as they join, and the owner can still take it back. The app chooses, so its users can pick the policy that suits them.

Session controls bar (opt-in). Nothing is drawn on your pages unless you ask. There are three ways to go:

  • No bar. Leave the placeholder out. The session still works; with ShareControl there are then no buttons to hand control over (use an unattended session, or draw your own).

  • The built-in bar. Put an empty <div id="rbwv-session-controls" data-share-link="true"></div> in your layout where the bar should sit. Each browser draws its own bar over it (status, Give control / Take control, Copy link for the owner, voice buttons). data-restart="true" adds Restart app; data-host-name / data-remote-name rename the two parties ("The host", "Remote user"), for example data-remote-name="The technician". Restyle with the rbwv-control-* / rbwv-voice-* classes.

  • Your own bar. Put a <template> inside the placeholder and mark its elements with data-rbwv. Each browser gets a copy with only the parts that apply to it; the status is filled in and the buttons are wired. Layout, wording, classes and icons are yours:

    <div id="rbwv-session-controls">
        <template>
            <span data-rbwv="dot"></span>
            <strong data-rbwv="status" data-text-you="You are driving"></strong>
            <button class="my-btn" data-rbwv="give">Hand over</button>
            <button class="my-btn" data-rbwv="take">Take back</button>
            <button class="my-btn" data-rbwv="copy-link" data-copied-text="Copied!">Invite</button>
        </template>
    </div>
    

    Parts: dot, status, give, take, copy-link, restart (with optional restart-question, restart-confirm, restart-cancel for a confirmation step), voice-status, voice-act, voice-mute, voice-end. On the status element data-text-you, data-text-view-only, data-text-none, data-text-switching and data-text-restarting replace the wording. A part left empty gets the built-in wording.

Put the placeholder in your layout, not on one page, or the bar goes away when the user navigates. It only shows when there is something to control: a session with an owner, or a voice call. A dot is lit while anyone is connected remotely; hovering over it says how many. For anything the template cannot do, window.RemoteControl (and window.RemoteVoice) expose the same state and actions to your own script; draw that in JavaScript above the page (not as a Blazor component: the app renders once for every browser, and clicks from whoever does not have control are dropped).

Restart button. Add data-restart="true" to the placeholder to give whoever has control (and the owner, always) a Restart app button, with a confirm step. The relay sends the app the same Refreshed event a browser refresh raises, so an app that restarts itself there needs nothing else; every browser page then waits for the new copy and loads again by itself. The button never appears without the placeholder.

With the source generator. [RemoteBlazor(nameof(RemoteBlazorWebView), ShareControl = true)] (or Unattended = true) generates this setup; see the generator's README.

Upgrade the relay and the packages together. Sharing control needs relay and packages 10.0.15 or later on both sides. With an older relay the Give control / Take control buttons do nothing. An app on older packages keeps working against a 10.0.15 relay.

Remote components. A remote component's frame follows the page it is on: it is usable in the browser that controls the app and read-only in the others, and moves with control. Viewers always see it read-only.

Sign-in on the relay

By default the relay asks nobody to sign in: a session's pages open for anyone who has the link. The Authorization:Provider setting (environment variable Authorization__Provider) chooses otherwise:

Provider What it does
None (default) No sign-in.
AzureB2C Azure AD B2C sign-in (settings: the AzureAdB2C section and Secret). In every relay build except the native one (-c NoAuthorization). A relay built with -c Authorization uses it without the setting.
Fake For tests: the request names its user as name;group1,group2 in the X-Rbwv-Fake-User header, the fake-user query value or the rbwv-fake-user cookie. The relay refuses to start with it outside the Development environment.

With sign-in on, a session's pages (/app, /mirror, /<id>, /status, /wait) open for a signed-in user whose groups include the session's Group, and for the app's own window, which needs no account: it opens its page with the owner key (below). Each connection's signed-in name is in the roster. A relay hosted in-process takes a provider directly: RemoteWebViewServerOptions.Authorization. A provider is an IRelayAuthorization.

Owner key. With ShareControl, the app makes a secret for the session (OwnerKey) and opens its own page as /app/<id>?role=owner&key=<key>. Only that page is the owner; ?role=owner added to any other link is ignored. ParticipantsChanged on the control reports who is in the session, their names and who has control.

Samples

Check out the tutorial at https://github.com/budcribar/RemoteBlazorWebViewTutorial

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on PeakSWC.RemoteWebView:

Package Downloads
PeakSWC.RemoteBlazorWebView.Wpf

This package will transport the user interface from an app built using BlazorWebView to a server running in the cloud. This allows an app running behind a firewall to be accessed through a browser by accessing the cloud server.

PeakSWC.RemoteBlazorWebView.WindowsForms

This package will transport the user interface from an app built using BlazorWebView to a server running in the cloud. This allows an app running behind a firewall to be accessed through a browser by accessing the cloud server.

PeakSWC.RemoteBlazorWebView

.NET 11 package that hosts a remote Blazor UI on Windows, Mac, and Linux

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
11.0.0 0 11/11/2026
11.0.0-rc2 75 10/25/2026
10.0.15.1 0 11/11/2026
10.0.15 42 11/11/2026
10.0.14 90 11/8/2026
10.0.13 415 10/19/2026
10.0.0-preview5 225 6/14/2025
10.0.0-preview4 315 5/14/2025
10.0.0-preview3 153 4/12/2025
9.0.22 81 11/6/2026
9.0.21 128 10/15/2026
9.0.6 1,936 6/15/2025
9.0.5 1,030 5/14/2025
9.0.4 371 4/12/2025
9.0.2 378 2/16/2025
9.0.1 368 1/18/2025
9.0.0 355 11/14/2024
9.0.0-rc2 196 10/26/2024
8.0.11 365 11/14/2024
8.0.10 1,641 10/10/2024
Loading failed

Based on maui 10.0.15.1

Changes since 10.0.14
Merge branch 'claude/session-bar-opt-in': session bar is opt-in, templates, restart keeps the owner role (10.0.15.1)
A page comes back from a restart with the query it was opened with
Session bar is opt-in: no placeholder, no bar; a template makes it the app's own
Merge branch 'claude/session-bar-slot-declared': session bar waits for a declared placeholder (10.0.15.1)
Generator README and ShareControl doc comment mention the host-page tag for the session bar
Version 10.0.15.1 (was 10.0.16): the first three parts follow the .NET release
Test: visibility waits take their own options type
Session bar waits for a declared placeholder instead of floating at startup (10.0.16)
Release workflow publishes to NuGet when dry_run is off (trusted publishing, nuget-org approval)
10-client test waits 2 minutes before attaching browsers again (idle sessions must survive)
Server stats tests: the app's own blazor.modules.json is served now (2 bytes fewer per client)
ParticipantsChanged needs relay 10.0.15
Merge PR #85 (module, JS, relay, lifecycle, generator and system test fixes)
README and release notes: sign-in providers, owner key, ParticipantsChanged
Authorization is injected, not compiled in: None, Fake (tests) and AzureB2C providers
Tests: owner URL carries the key; spoofed-owner test waits for the roster
WinForms: OwnerKey is not a designer property
WIP: owner key, names in the roster, ParticipantsChanged, session group check
Remove UTF-8 BOM from embedded blazor.modules.json and clear CS8602 warnings
Use bundled protoc 3.x binary in scripts/protoc.js on Linux CI
Fix bugs across module, JS, relay, lifecycle, generator, and system tests
Browser swarm keeps 300 separate clients, spread over 10 Chromium processes
Fix RunTests.ps1 packaging/tool issues, concurrent browser tests, and MSB3277 warnings
RunTests: -NoBuild runs the tests on what the last run built
Lost-connection test cuts the viewer's connections itself
A lost connection is shown and a /mirror page comes back; unattended hand-over retried; frames follow the latest control change
Web.JS test file as EditWebView writes it
EditWebView keeps this repository's own changes across a run
Upstream source from MAUI 10.0.130 and aspnetcore 10.0.15 (EditWebView run)
Document EditWebView in the release process.
EditWebView: ask for tag dates only on the wanted major version, and print progress
EditWebView prints what a run changed; Web.JS/src and test no longer git-ignored
update packages
EditWebView: fall back to the GitHub CLI sign-in when GITHUB_PAT is not set
Microsoft 10.0 libraries to 10.0.15, SDK 10.0.404; EditWebView re-applies the Web.JS patches
Control test: a browser that has not been told yet is 'not agreed', not an error
Restart test: wait for the restart to start before waiting for the page to return
RunTests: -Filter for a partial browser run; restart test keeps the bar in view
Agent: hand the requester the session's join link
Generator: voice, run-time choices, app-supplied startup values, and a restart that survives a stuck window
Library: a restart request still restarts an app whose UI thread is stuck
Session bar: opt-in Restart button
Shared control: one change of controller at a time
Voice: a mirror page gets the remote end whenever nobody holds it
Relay: every write to the app's stream goes through one guarded method
Shared control: a message from before a hand-off can no longer replace a real one
RunTests: quote the -p: switch so PowerShell passes it whole
RunTests: run every test project, quick suites first
BugBountyTests: the mirror-scroll test ignores the control notices browsers are now sent
ControlTransferTests: the fake browser stream accepts the relay's token overload
Tests for sharing control: relay policy, render acks, URL loading, and end-to-end browser tests

Full list: https://github.com/budcribar/RemoteBlazorWebView/compare/10.0.14...227d88ffc73906e1f5d6999da10e6962b1fe51cb