How do favicons work in next 13 pages dir?
Unanswered
Somali posted this in #help-forum
SomaliOP
i just put favicon.ico in public folder and thats work, but i dont see any link rel="icon" or something with path to favicon and that work.
how is possible?
this is not ssg?
how is possible?
this is not ssg?
12 Replies
@Somali i just put favicon.ico in public folder and thats work, but i dont see any link rel="icon" or something with path to favicon and that work.
how is possible?
this is not ssg?
If browsers don’t see an icon declaration it should automatically fetch /favicon.ico and use it as the favicon
@joulev If browsers don’t see an icon declaration it should automatically fetch /favicon.ico and use it as the favicon
SomaliOP
oh okay. should i do something with apple-icon or 32x32 or 16x16 sizes?
in app router we have good docs about this, what about pages dir?
in app router we have good docs about this, what about pages dir?
i have something like this
you should manually set the meta tags in the header that you make in pages dir
@Somali oh okay. should i do something with apple-icon or 32x32 or 16x16 sizes?
in app router we have good docs about this, what about pages dir?
I don’t know about other icons and I wouldn’t rely on browsers automatically fetching /favicon.ico. You should still declare them explicitly in <head>. In the pages router you use next/head and/or _document.js
next-seo will help a lot if you go the next/head path
@joulev I don’t know about other icons and I wouldn’t rely on browsers automatically fetching /favicon.ico. You should still declare them explicitly in <head>. In the pages router you use next/head and/or _document.js
SomaliOP
yeah, i can do this manually, but may be i looking something like 'favicon generator'
@Somali yeah, i can do this manually, but may be i looking something like 'favicon generator'
There should be plenty of those online
I don’t have any recommendations, but anything coming up on top with “favicon generator†or “seo tag generator†should do well
@joulev There should be plenty of those online
SomaliOP
im mean, i dont wanna store 999 variant of favicons in public dir
@Somali im mean, i dont wanna store 999 variant of favicons in public dir
that would be the same issue for app dir btw
@riský that would be the same issue for app dir btw
SomaliOP
You're right, this is probably out of the scope of the original question.