Meta-Lens
Preview · Validate · Optimize What is Meta-Lens?Meta-Lens is a VS Code extension that gives you a live SEO and accessibility audit dashboard for any locally-running web page. Instead of deploying to staging to test your meta tags, you run your dev server and open Meta-Lens — within seconds you see your SEO score, social media previews, accessibility issues, and crawler validation, all without leaving your editor.
Features
Getting StartedStep 1 — Start your dev server
Step 2 — Open Meta-LensChoose any of these:
Step 3 — Browse the tabs
SEO ValidationMeta-Lens scores your page from 0–100 and reports Errors, Warnings, and Suggestions:
Accessibility AuditAutomated WCAG-based checks (score 0–100):
Crawler DashboardMeta-Lens fetches and validates crawler configuration files from your origin:
|
| Framework | Pattern detected |
|---|---|
| Next.js App Router | app/**/page.tsx |
| Next.js Pages Router | pages/**/*.tsx |
| Astro | src/pages/**/*.astro |
| Nuxt | pages/**/*.vue |
| SvelteKit | src/routes/**/+page.svelte |
Click any static route to instantly preview its metadata.
Export Report
Click the ⬇ Download button in the top header to export a formatted seo-report.html to your workspace root. The report includes:
- SEO score and Accessibility score
- Full list of errors, warnings, and suggestions with fix hints
- Timestamp and URL
Open the file in a browser and print to PDF for sharing with your team.
CLI Usage
# Install globally (after publishing to npm)
npm install -g @csedge-foundry/metalens
# Run a quick audit from the terminal
metalens preview http://localhost:3000
metalens preview https://yoursite.com
Output:
Meta-Lens — http://localhost:3000
SEO Score: 74/100
❌ Missing og:image
⚠ Title too long (68 chars)
⚠ No canonical URL set
ℹ No JSON-LD structured data found
Accessibility Score: 90/100
⚠ 2 images missing alt attribute
Configuration
Open VS Code Settings (Ctrl+,) and search Meta-Lens, or add to settings.json:
{
// Default port when auto-detection finds nothing
"meta-lens.defaultPort": 3000,
// Auto-refresh when you save a file
"meta-lens.autoRefresh": true,
// Scan common ports automatically on open
"meta-lens.autoDetectPort": true
}
Ports scanned automatically: 3000, 3001, 4000, 4321, 5173, 5174, 8000, 8080, 8888, 9000
How It Works
Developer saves file
↓
VS Code fires onDidSaveTextDocument
↓
MetaLensPanel fetches HTML from localhost
↓
Parser extracts all <head> meta tags
↓
Fetcher checks /robots.txt, /llms.txt, /sitemap.xml
↓
SEO engine scores & validates (0–100)
↓
Accessibility engine runs WCAG checks
↓
React webview renders all tabs instantly
Supported Frameworks
| Framework | Route Detection | Metadata Reading |
|---|---|---|
| Next.js (App Router) | ✅ | ✅ |
| Next.js (Pages Router) | ✅ | ✅ |
| Astro | ✅ | ✅ |
| Nuxt | ✅ | ✅ |
| SvelteKit | ✅ | ✅ |
| React (Vite / CRA) | — | ✅ |
| Vue (Vite) | — | ✅ |
| Angular | — | ✅ |
| Plain HTML | — | ✅ |
| WordPress / Laravel / Django / any server | — | ✅ |
Troubleshooting
Panel shows blank / "Detecting localhost server..."
Your dev server isn't running. Start it first (npm run dev), then click Open Preview or use the address bar to type your URL manually.
"Failed to fetch" / "Nothing is running on localhost:3000"
Verify your dev server is up and listening on the expected port. Type the correct URL in the Meta-Lens address bar (e.g., http://localhost:5173).
Preview shows stale data
Click ↻ Refresh, or check that meta-lens.autoRefresh is true in settings.
Routes tab shows nothing
Open Meta-Lens from within a Next.js, Astro, Nuxt, or SvelteKit project. The extension scans from the workspace root.
og:image doesn't load in the preview
The image URL in your og:image tag must be accessible from your local machine. Relative paths like /og.png are resolved against the localhost origin.
Roadmap
| Feature | Version |
|---|---|
| VS Code Marketplace launch | v1.0 |
| Structured data deep validation | v1.1 |
| Lighthouse-style performance score | v1.1 |
| Bulk route audit (scan all pages at once) | v1.2 |
| Shareable JSON audit report | v1.2 |
| OpenAI / Gemini AI fix suggestions | v2.0 |
| Browser extension (Chrome / Firefox) | v2.0 |
| Cloud sync & history | v2.0 |
Want a feature? Open an issue.
Contributing
See CONTRIBUTING.md for the full development setup guide.
Quick start:
git clone https://github.com/Durgesh-Vaigandla/meta-lens.git
cd meta-lens
npm install
npm run watch
# Press F5 in VS Code to launch the Extension Development Host
License
MIT © Durgesh Vaigandla — CSEdge