Automatically inserts the current file path at the top of your files as a comment.
Perfect for:
- Large projects
- React / Expo apps
- Sharing screenshots
- AI prompts
- Faster navigation
- Team collaboration
Features
✅ Insert relative file path as comment
✅ Supports many programming languages
✅ Auto insert on save
✅ Manual command support
✅ Keyboard shortcut support
✅ Updates existing path automatically
✅ Lightweight and fast
Example
JavaScript / TypeScript
// @path: src/components/Button.jsx
Python
# @path: app/utils/helper.py
Html
<!-- @path: public/index.html -->
Supported Languages
- JavaScript
- JSX
- TypeScript
- TSX
- Python
- Java
- Kotlin
- C
- C++
- Go
- Rust
- PHP
- HTML
- XML
- SVG
- CSS
- SCSS
- SASS
- LESS
- Shell
- YAML
- Markdown
- Vue
- Svelte
- SQL
- Lua
- INI
- ENV files and more...
Keyboard Shortcut
Windows / Linux
Ctrl + Alt + P
Mac
Cmd + Alt + P
Commands
Open Command Palette:
Insert File Path Comment
Auto Insert On Save
When enabled, the extension automatically inserts:
// @path: src/screens/HomeScreen.jsx
when you save a file.
Ignored Folders
The extension automatically ignores:
- node_modules
- .git
- dist
- build
- .next
- .expo
- .turbo
- Installation
From VSIX
Open VSCode
Go to Extensions
Click ...
Select:Install from VSIX
Select the .vsix file
Development
Install dependencies
npm install
Run extension
Press: F5
Package extension
vsce package
Why Use Path Header?
In large projects, it becomes difficult to:
identify files quickly share snippets debug screenshots work with AI tools
Path Header solves this by embedding the relative file path directly inside the file.
Future Plans
Custom path formats Absolute path support Toggle auto insert Status bar controls Workspace settings Import alias support Better config file detection License
MIT License