Next.js Discord

Discord Forum

<title> doesn't work

Answered
Masai Lion posted this in #help-forum
Open in Discord
Masai LionOP
Hey, I'm using a code like this in my client/server pages :

        import Head from "next/head";

        <div className={`flex flex-col justify-center items-center`}>
            <Head>
                <title>
                    Frequently asked questions
                </title>
            </Head>

        .....
        </div>


But this doesn't work in any page. The title remains the domain of the app. Do you know why ?
Answered by joulev
next/head doesn't work in the app router
View full answer

6 Replies

Answer
use metadata for that
@joulev use metadata for that
Masai LionOP
Alright thanks, dynamic metadata is not a problem for SEO ?
no not a problem
Masai LionOP
Alright, cool !