skip to Main Content

I built out a nextjs 13 webapp using clerk for auth. The issue is that the homepage of the web app isn’t discoverable on Google. when i Test Live URL, this is how it looks:
enter image description here

I’ve done basic implementation of seo in the app. But i see this in vercel whenever i try to crawl the website:
enter image description here

I suspected Clerk Middleware is the issue, but i’ve added homepage in public routes enter image description here

If someone can help, that’d be very helpful!

2

Answers


  1. I was getting Unauthorized using clerk middleware aswell but I couldn’t figure out a solution, so I just go back to previous middleware version and everything works fine. (sorry bad English)

    import { withClerkMiddleware } from "@clerk/nextjs/server";
    import { NextResponse } from "next/server";
    import type { NextRequest } from 'next/server'
    
    export default withClerkMiddleware((req: NextRequest) => {
      return NextResponse.next();
    });
    
    // Stop Middleware running on static files
    export const config = { matcher:  '/((?!_next/image|_next/static|favicon.ico).*)',};
    
    Login or Signup to reply.
  2. Also having this same issue with next and clerk, It happens when I try to embed a public route inside an iframe on another website.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search