Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Nifty C# Scratchpad: Run C# Snippets & NuGetNew to Visual Studio Code? Get it now.
Nifty C# Scratchpad: Run C# Snippets & NuGet

Nifty C# Scratchpad: Run C# Snippets & NuGet

Nifty

| (0) | Free
Run C# snippets instantly with NuGet packages and rich Dump() output, a LINQPad-style scratchpad and Polyglot Notebooks replacement.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Nifty C# Scratchpad

Run C# snippets instantly with NuGet packages and rich Dump() output: a LINQPad-style scratchpad and Polyglot Notebooks replacement.

Maintained. No sign-in. No telemetry. Works in VS Code, Cursor, Windsurf, VSCodium and other editors that use Open VSX.

Why

Polyglot Notebooks and .NET Interactive were discontinued in 2026, and LINQPad is a separate app. Nifty C# Scratchpad gives you a quick place to try C# code, explore data and test a NuGet package, right inside your editor. It's built on .NET 10's official dotnet run file.cs, so it uses the real compiler and runtime.

Features

LINQ over some orders pasted into a scratchpad and run with Ctrl+Enter, its Dump() results appearing as tables beside it

A scratchpad with LINQ over some orders, and its Dump() results as tables beside it

A compile error shown in the output and in Problems, on the scratchpad's own line

  • Scratchpads in one keystroke. Ctrl+Alt+Shift+N creates a new scratchpad. Your scratchpads are kept for next time (Open Scratchpad…).

  • Run with Ctrl+Enter in a scratchpad (Ctrl+Alt+Enter in any C# file), the ▶ button, or the Run CodeLens at the top. Runs take about a second once built.

  • Dump() anything.

    var orders = db.Orders.Where(o => o.Total > 100).Take(20).ToList();
    orders.Dump("Big orders");
    

    Lists of objects become tables, nested objects become expandable tables, and numbers, strings, booleans and nulls are colour-coded. Dump() returns its value, so you can chain it. Large sequences are cut off at 1,000 items (Dump(maxItems: 50) to change).

  • NuGet packages in one step. Add NuGet Package… searches nuget.org and adds a line like #:package Dapper@2.1.35; it's restored automatically on the next run.

  • Compile errors where you need them. In the output panel (click to jump to the line) and in the Problems panel.

  • Any .NET 10 file-based app. Also runs .cs files in your projects that use top-level statements or #:package / #:sdk directives.

  • Export output as an HTML report, JSON, or CSV (one Dump() at a time).

  • Run on save: scratchpads re-run every time you save.

  • Snippet library: save and insert reusable code across scratchpads.

  • Stop long-running code at any time.

  • Private. .NET CLI telemetry is switched off for every run the extension starts.

Requirements

The .NET 10 SDK or newer. Nifty C# Scratchpad finds it on your PATH or in the standard install locations, or set nifty.csharp-scratchpad.dotnetPath.

For IntelliSense in scratchpads, use the C# extension (or C# Dev Kit) as usual.

Commands

Command Key What it does
Run Scratchpad Ctrl+Enter in scratchpads, Ctrl+Alt+Enter in C# files Build and run
Stop Stop the running code
New Scratchpad Ctrl+Alt+Shift+N Create a scratchpad
Open Scratchpad… Pick an existing scratchpad
Add NuGet Package… Search nuget.org and add a #:package line
Reveal Scratchpad Folder Show where scratchpads are stored
Export Output… HTML, JSON or CSV
Toggle Run on Save Re-run when you save
Save to / Insert from Snippet Library Reusable snippets

Settings

Setting Default What it does
nifty.csharp-scratchpad.dotnetPath (empty) Path to dotnet; empty means find it automatically
nifty.csharp-scratchpad.runArguments [] Extra dotnet run arguments, e.g. ["-c", "Release"]
nifty.csharp-scratchpad.codeLens true Show Run / Add NuGet Package above runnable files

Install

  • VS Code: search for "Nifty C# Scratchpad" in the Extensions view, or install from the Visual Studio Marketplace.
  • Cursor, Windsurf, VSCodium, Kiro, Antigravity: install from Open VSX.

Privacy

This extension collects no telemetry and needs no account. It contacts nuget.org only when you search for a package.

More Nifty tools

  • Nifty C# Templates: New Class, Record & Namespace: New C# class, interface, record, enum, test and controller files with the right namespace, plus namespace syncing. (Open VSX)
  • Nifty NuGet: NuGet Package Manager: Search, add, update and remove NuGet packages, see outdated and vulnerable ones, in VS Code, Cursor and every editor. (Open VSX)
  • Nifty Code Runner: Run Code in 25+ Languages: Run the current file or selection in 25+ languages in the terminal, with input support, your own commands and no telemetry. (Open VSX)
  • Nifty Docstrings: Doc Comments for Python, PHP, Rust and Go: Type three quotes under a Python function and get a Google, NumPy or Sphinx docstring with its arguments, types, returns and raises. PHPDoc, Rust and Go doc comments too. (Open VSX)
  • Nifty Env: .env Files, Profiles & Secrets: Load .env files into terminals, tasks and debug sessions, switch between .env profiles, hide secret values on screen, and check .env against .env.example. (Open VSX)
  • Nifty Launch: launch.json Generator & Checker: Add debug configurations for what's in your project (npm scripts, tests, Python, Django, FastAPI, Go, .NET, Rust, browsers), build compounds, and catch broken launch.json references. (Open VSX)

See all 42 Nifty tools at https://getnifty.dev

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft