nextjs-seomplementation

Guide SEO metadata, OG images, and robots configuration in Next.js 16 App Router.

2|Updated Dec 6, 2025
One-click install
npx skills add https://github.com/Ali1raz/portal-cui --skill nextjs-seomplementation
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: nextjs-seomplementation
Source: https://github.com/Ali1raz/portal-cui/tree/main/.github/skills/nextjs-seo-implementation
Command: npx skills add https://github.com/Ali1raz/portal-cui --skill nextjs-seomplementation

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This skill addresses the complexity of SEO in Next.js applications, particularly for the App Router, by guiding the setup of metadata, Open Graph images, and robots configuration across both public and authenticated sections.

Core Features & Use Cases

  • SEO Setup Guide: Walks through four phases to systematically enhance SEO for Next.js apps with App Router.
  • Public vs. Protected Pages: Offers strategies for handling public and authenticated content distinctly.
  • Metadata Configuration: Helps configure site-wide defaults and page-specific metadata.
  • OG Image Strategies: Provides options for static, dynamic, and custom OG image implementations.
  • Robots Metadata: Guides the use of robots.txt and page-level metadata to control indexing.

Quick Start

Execute the skill to analyze your application's architecture, set up root metadata, implement page-level metadata, and configure robots metadata for enhanced SEO.

Frequently Asked Questions about nextjs-seomplementation

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement SEO metadata in a Next.js App Router application?

Next.js App Router SEO implementation involves configuring root metadata objects for site-wide defaults and exporting page-specific metadata to override titles, descriptions, and Open Graph data per route. It requires understanding server-side rendering to properly render SEO tags.

What is the best way to generate dynamic Open Graph images in Next.js?

Dynamic Open Graph images in Next.js are best handled by using the ImageResponse API within a route handler. This approach allows you to programmatically build OG images based on route parameters or database content for production-grade social sharing.

How do I configure robots.txt and control page indexing in Next.js?

Configure robots.txt in Next.js by adding a robots.ts file at the app root to define static crawl rules. For granular page indexing control, export a robots metadata object from specific route segments to override global directives.

Can I handle SEO differently for public and authenticated pages in Next.js?

Handling SEO differently for public and authenticated pages in Next.js is achieved by using role-specific layouts. This strategy allows you to apply standard metadata to public sections while configuring noindex tags or restricted crawl behavior for protected content.

What do I need to know before setting up Next.js App Router SEO?

Before setting up Next.js App Router SEO, you need knowledge of the Next.js framework, an understanding of core SEO concepts, and the ability to handle server-side rendering and client-side interactions within your application architecture.