Sequence NODE_207
Easy

Add Static Metadata to a Page

Next.js
React
JavaScript
Technical Specification

Add static title and description metadata for a page using the metadata export.

Input/Output Samples
Input:Page /resources
Output:Custom tab title
Optimal Logic Path
export const metadata = {
  title: "Resources - CodeWithHappy",
  description: "Free web dev resources.",
};

export default function ResourcesPage() {
  return <main>Resources</main>;
}
Architectural Deep-Dive
Static metadata is baked into the HTML and improves SEO and social previews.