Morteza Negahi Morteza Negahi - 1 month ago 5
HTML Question

How to hide Laravel paginate in search engines

How can I hide pages render in search engines . and google just Identified for example blog, Not blog?page=5.

Can i do this with Canonical URL?

enter image description here

nXu nXu
Answer

Google's documentation says you should not worry about this, this is how they index your page. Best you can do is to provide rel="prev"andnext` links:

If you paginate content on your site, and you want that content to appear in search results, we recommend one of the following three options.

  • Do nothing. Paginated content is very common, and Google does a good job returning the most relevant results to users, regardless of whether content is divided into multiple pages.
  • Specify a View All page. Searchers commonly prefer to view a whole article or category on a single page. Therefore, if we think this is what the searcher is looking for, we try to show the View All page in search results. You can also add a rel="canonical" link to the component pages to tell Google that the View All version is the version you want to appear in search results.
  • Use rel="next" and rel="prev" links to indicate the relationship between component URLs. This markup provides a strong hint to Google that you would like us to treat these pages as a logical sequence, thus consolidating their linking properties and usually sending searchers to the first page.