Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Nifty Nginx: nginx.conf Formatting & IntelliSenseNew to Visual Studio Code? Get it now.
Nifty Nginx: nginx.conf Formatting & IntelliSense

Nifty Nginx: nginx.conf Formatting & IntelliSense

Nifty

|
1 install
| (0) | Free
nginx config support: syntax highlighting, formatting, directive completion and docs on hover, context checks, and snippets for reverse proxies, SSL and PHP.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Nifty Nginx

nginx config support: syntax highlighting, formatting, directive completion and docs on hover, context checks, and snippets for reverse proxies, SSL and PHP.

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

Features

Directive completion inside a location block, with its docs

Hover docs for try_files

A missing semicolon listed in Problems as you type

  • Highlighting for nginx configs. nginx.conf, files in sites-available, sites-enabled, conf.d and snippets, .nginx files and other files that start like an nginx config. Directives, blocks, variables, strings, sizes and URLs are all colored.
  • Format Document. Blocks are re-indented and spacing tidied (listen 80; becomes listen 80;), with one statement per line, while comments and quoted strings are kept exactly as they are.
  • Completion that knows where you are. Inside a location, you're offered proxy_pass, try_files and fastcgi_pass, not listen or worker_processes. Block directives insert their braces.
  • Docs on hover. Hover any directive for its syntax, a plain-English explanation, where it's allowed and a link to its page on nginx.org.
  • Mistakes caught before nginx -t. A missing ;, a } too many or too few, proxy_pass directly in http, or listen with a block are underlined as you type.
  • Outline and breadcrumbs for http, server (named by server_name, with its port), location and upstream blocks.
  • Snippets for the configs everyone writes: proxy, ssl, https-redirect, websocket, php, spa, cache-static, gzip, ratelimit, basic-auth, upstream, security-headers.
  • Test Configuration runs nginx -t and shows the result. For a site or snippet it tests the nginx.conf that sits in its folder or a folder above (or your main config setting).
  • Included snippets (files without http { }) are understood, so they don't light up with false errors.
  • Works in the browser on vscode.dev and github.dev; Test Configuration (nginx -t) needs the desktop app.

Commands

Command What it does
Nifty Nginx: Test Configuration (nginx -t) Validate with nginx itself (needs nginx installed)
Nifty Nginx: Format Configuration Same as Format Document

Settings

Setting Default What it does
nifty.nginx.validate true Check the config as you type
nifty.nginx.checkContexts true Warn about directives in the wrong block
nifty.nginx.flagUnknownDirectives false Point out directives Nifty Nginx doesn't know
nifty.nginx.nginxPath nginx The nginx executable for Test Configuration
nifty.nginx.mainConfig "" Main config to test (empty: the current file, or the nginx.conf above a site or snippet)

Install

  • VS Code: search for "Nifty Nginx" 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.

More Nifty tools

  • Nifty HCL Tools: .tf and .hcl Language Support: Fast, lightweight Terraform and OpenTofu support: highlighting, outline, go to definition and references across a module, hovers, completion, undefined-reference errors and formatting. (Open VSX)
  • Nifty Templates: Jinja, Twig & Nunjucks: Jinja, Twig and Nunjucks: highlighting in HTML, YAML and any file, block formatting, outline and folding, unclosed-tag errors, completion with docs, snippets, and go to definition for templates. (Open VSX)
  • Nifty TOML: Format, Validate & Schemas: TOML support: highlighting, errors, a formatter that keeps comments, outline, folding, and JSON Schema validation, completion and hover (Cargo.toml, pyproject.toml via SchemaStore). TOML to JSON/YAML. (Open VSX)
  • Nifty XML: XPath, Formatter & XML to JSON: Evaluate XPath with namespaces, copy the XPath of any element, format, minify, check well-formedness and convert XML to JSON. (Open VSX)
  • Nifty YAML: Formatter, Validator & Converter: Format YAML without losing comments (Kubernetes-style indents), sort keys, lint with yamllint, copy the key path, and convert to and from JSON. (Open VSX)
  • 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)

See all 100+ Nifty extensions and web tools at https://getnifty.dev

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