Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Comment BeautifierNew to Visual Studio Code? Get it now.
Comment Beautifier

Comment Beautifier

Y3191

|
42 installs
| (0) | Free
Format and align your code comments automatically. Makes comments more readable by adjusting indentation and alignment
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

English | 日本語

Comment Beautifier - VS Code Extension

This is a Visual Studio Code extension that aligns comment indentation.

Demo

Features ✨

  • Two alignment options for comments:
    • Left alignment (minimum indentation)
    • Right alignment (maximum indentation)
  • Supports multiple programming languages:
    • TypeScript/JavaScript
    • Python
    • Java
    • C/C++
    • C#
    • PHP
    • Ruby
    • Go
    • Rust
    • Swift
    • SQL
    • Gradle (Kotlin DSL)

Usage 💡

  1. Select the code block containing comments you want to format
  2. Right-click and select either:
    • "Align Comments Left" for minimum indentation
    • "Align Comments Right" for maximum indentation
  3. Comments will be aligned according to your choice

⚠️ Note: To properly align comments, be sure to select the entire code block from the first to the last character. Partial selections may lead to unexpected formatting results.

Example

Before:

function example() {
// This is a comment
  // Another comment
    // One more comment
}

After (Left alignment):

function example() {
// This is a comment
// Another comment
// One more comment
}

After (Right alignment):

function example() {
    // This is a comment
    // Another comment
    // One more comment
}

Change Log 📝

You can checkout all our changes in our CHANGELOG.

Installation 🔧

  1. Open Visual Studio Code
  2. Press Ctrl+P (Windows/Linux) or Cmd+P (macOS)
  3. Type ext install comment-beautifier
  4. Press Enter

License ⚖️

MIT


Give it a try! ✨

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft