Native Desktop Application Framework

Build native desktop applications for Windows (with future support planned for macOS and Linux) using 'R' and embedded 'webviews'. Provides a robust 'R6'-based event loop, asynchronous background task management via 'mirai' and 'callr', and a native message bridge for seamless 'R'-to-user-interface communication without listening ports or network overhead. Allows 'R' developers to create professional, standalone desktop tools with modern web-based user interfaces while maintaining a pure 'R' backend.


RDesk

RDesk hex logo

CRAN status Lifecycle: experimental R-CMD-check pkgdown MIT license Windows

Package R analyses into self-contained native desktop applications with zero network port requirements.


RDesk packages your R analysis into a standalone desktop application for Windows (with future support planned for macOS and Linux). Instead of running an HTTP server and opening a browser tab, RDesk uses a native launcher plus an embedded webview so the app runs offline with local IPC only.

Quick Start

# Install from CRAN
install.packages("RDesk")

# Scaffold an interactive app
RDesk::rdesk_create_app("MyApp")

# Run it immediately
source("MyApp/app.R")

When you are ready to ship:

RDesk::build_app(
  app_dir         = "MyApp",
  app_name        = "MyApp",
  build_installer = TRUE
)

# Windows -> dist/MyApp-1.0.0-setup.exe (or dist/MyApp-1.0.0-windows.zip)

Windows produces a standalone installer or portable zip distribution (with macOS and Linux packaging in active development). No separate R installation or browser server is required on the target machine when using the bundled runtime.

Development version

devtools::install_github("Janakiraman-311/RDesk")

Why RDesk?

Feature Shiny RInno (archived) Electron + R RDesk
Network ports required Yes Yes Yes No
Works fully offline No Partial Partial Yes
Native file dialogs and menus No No Via JS Yes
Distribution format Server URL Installer Installer Bundle or installer
Bundle size Server-side 350 MB+ 350-500 MB ~200 MB
Skills required R R + Electron R + Node.js R only

Core Features

  • Zero-port IPC - R and the UI communicate through native stdin/stdout pipes and platform webview bindings, without opening network ports.
  • Async by default - Non-blocking background work using mirai and callr with support for progress updates, loading states, and cancellation.
  • Version-safe runtime - build_app() bundles a matching R runtime so the shipped app and its packages stay aligned.
  • Modern web UI - Build the interface with plain HTML, CSS, and JavaScript while keeping the backend in R.
  • Automated scaffolding - rdesk_create_app() generates a working application template with handlers, structure, and theme support.
  • Native packaging - Produce platform-specific bundles and installers without adopting a browser-server deployment model.

Who It's For

RDesk is built for R developers who need to package a local statistical or data tool for non-R users.

  • Pharma and clinical - distribute review or validation tools for offline execution.
  • Consulting - package analytical models into branded tools without exposing source code.
  • Internal teams - replace complex spreadsheet macros with structured R applications.
  • Restricted environments - ship local tools where listening ports are disallowed or heavily scrutinized.

Example Apps

Two apps ship with RDesk demonstrating different complexity levels.

CarsAnalyser - minimal dashboard

app_dir <- system.file("apps/mtcars_dashboard", package = "RDesk")
source(file.path(app_dir, "app.R"))

Data Intelligence Studio - full-featured data profiling tool

app_dir <- system.file("apps/data_studio", package = "RDesk")
source(file.path(app_dir, "app.R"))

Documentation

Full documentation is available at janakiraman-311.github.io/RDesk.

Guide What it covers
Getting Started From install.packages() to your first native app
Coming from Shiny Side-by-side mapping of common Shiny patterns to RDesk
Async Guide Background tasks, progress overlays, cancellation
Cookbook Practical desktop-app recipes
Why RDesk? Project background and architecture

License

MIT (c) Janakiraman G.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("RDesk")

1.0.7 by Janakiraman G, a month ago


https://github.com/Janakiraman-311/RDesk, https://janakiraman-311.github.io/RDesk/


Report a bug at https://github.com/Janakiraman-311/RDesk/issues


Browse source code at https://github.com/cran/RDesk


Authors: Janakiraman G [aut, cre, cph] (ORCID: , Serge Zaitsev [cph] (Author of webview library (src/webview/webview.h)) , Steffen André Langnes [cph] (Contributor to webview library (src/webview/webview.h)) , Björn Hoehrmann [cph] (Copyright holder credited in nlohmann/json) , Florian Loitsch [cph] (Copyright holder credited in nlohmann/json) , Niels Lohmann [cph] (Author of nlohmann/json (inst/include/nlohmann/json.hpp)) , Evan Nemerson [cph] (Copyright holder credited in nlohmann/json) , The Abseil Authors [cph] (Copyright holder credited in nlohmann/json) , Microsoft Corporation [cph] (WebView2 SDK (src/webview2_sdk/))


Documentation:   PDF Manual  


MIT + file LICENSE license


Imports R6, jsonlite, digest, processx, callr, mirai, base64enc, zip, stats, utils, parallel

Suggests testthat, withr, knitr, rmarkdown, ggplot2, dplyr, broom, devtools, pkgbuild, rstudioapi, renv

System requirements: Windows 10 or later, Microsoft 'WebView2' Runtime (https://developer.microsoft.com/microsoft-edge/webview2/)


See at CRAN