Requirements:
1. Create sitemap.xml
- Add a dynamic sitemap.xml file for the website.
- Include all public frontend pages.
- Include dynamic pages also, like:
- Products
- Categories
- Services
- Blogs
- Other public detail pages
- Sitemap should generate URLs dynamically from database records where needed.
- Add lastmod, changefreq, and priority values.
- Sitemap URL example:
https://domain.com/sitemap.xml
2. Create robots.txt
- Add robots.txt file.
- Allow search engines to crawl public website pages.
- Block admin panel, API private routes, login pages, dashboard pages, and sensitive URLs.
- Add sitemap URL inside robots.txt.
Example:
User-agent: *
Allow: /
Disallow: /admin
Disallow: /admin/*
Disallow: /api/*
Disallow: /login
Disallow: /dashboard
Sitemap: https://domain.com/sitemap.xml
3. Admin Panel SEO Management Page
Create one SEO management page in the admin panel.
Page Name:
SEO Management
Admin route example:
/admin/seo
This page should allow admin to manage SEO details for all frontend pages from one place.
4. SEO Fields Required
For each page, admin should be able to add/edit:
Basic SEO:
- Page Name
- Page URL / Slug
- Meta Title
- Meta Description
- Meta Keywords
- Canonical URL
- Robots Meta
- index, follow
- noindex, follow
- index, nofollow
- noindex, nofollow
Open Graph / Social Sharing:
- OG Title
- OG Description
- OG Image
- OG Type
- OG URL
Twitter Card:
- Twitter Title
- Twitter Description
- Twitter Image
- Twitter Card Type
Advanced SEO:
- Schema JSON-LD
- Custom Head Script
- Status: Active / Inactive
5. Admin SEO Page UI
Create a clean table listing all pages.
Table columns:
- Page Name
- Page URL
- Meta Title
- Status
- Last Updated
- Action buttons: Edit / Delete
Also add:
- Search option
- Add New SEO button
- Edit SEO form
- Image upload option for OG Image and Twitter Image
6. Frontend SEO Integration
On every frontend page:
- Fetch SEO data based on current page slug or URL.
- Dynamically apply:
- title
- meta description
- meta keywords
- canonical URL
- robots meta
- OG tags
- Twitter tags
- schema JSON-LD
0 comments:
Post a Comment