Wordpress noindex
-
Hi there,
Does anyone no of a way to noindex all the "previous entries" pages in a wordpress blog. They usally show on domain.com/page/2/ etc. They are the small snippets that provide a summary of the all your posts.
I've not been able to find a plugin to do this.
Thanks so much!
-
Thanks, this helped me
-
Brilliant. Glad I could help.
-
I fully understand that. People at my work fully advocate the use of plugins, I personally believe that somethings should be hard-coded into the theme (This being one of those things).
Chances are once you find an SEO plugin you tend to stick with it until you notice issues or find one that does things better.
I'm surprised that WordPress doesn't do more to help prevent duplicate content.
-
Thanks so much Ben, This has done exactly what I wanted
-
I agree Ben, that coding into the theme itself is the best way to do this - however since there are a few ways to do this task - we wanted to offer various solutions.
-
Also, if you use the plugin to set the posts to no-follow and you want to change SEO plugin changes are those settings won't be transferred, if you code the solution into the theme its plugin independent and (in my eyes) the best way to go about avoiding duplication in WordPress.
-
This seems overly complex for a coding solution. All you need is 3 lines of code (max) in header.php of your theme (See my reply above)
-
That will only put noindex on the date archives.
I noticed the same problem and wrote an article on how to avoid duplication in WordPress. For a fresh WordPress installation with 10 published posts, Google ends up indexing close to 30 URLs, all pointing back to just 10 unique articles, because of the date, author and category archive pages.
In header.php of your theme add the following code:
1){ echo ''; } ?> '; } ?> '; } ?>
If you want, this could be condensed to:
$paged > 1 || is_author() || is_trackback()){ echo ''; } ?>
You can read more at my blog: http://www.laceytechsolutions.co.uk/blog/wordpress-development/avoiding-duplicate-content-in-wordpress
-
There is a plugin way – and a coding way…
I will explain both
Plugin version is good for individual posts / coding way is a mass archive way…
PLUGIN VERSION
Using a plugin called WordPress SEO by Yoast.. you can go into the previous posts and do the following.
Open the POST dashboard in your WordPress blog.
Find the post/s you are interested in working with.
Click ‘Edit’ post
Then scroll down to the WordPress SEO by Yoast section on the bottom anc click ADVANCED
From there.. you can select noindex / nofollow for that post – as well as a few advanced meta tags.
You can do this for any or all of your posts…
CODING VERSION
Step 1
In your theme folder locate the following files:/wp-content/themes/yourtheme/
Archive.php
Header.php
Open them both up.
Step 2
First thing to do is SAVE the header file as:header-archive.php
with that new version open add the following code into the header section:
Then save it.
Upload that file to your wp theme folder online.
Step 3 now go to the open archive.php file and find and replace the following:
FIND:
REPLACE WITH:
Save and upload that file to your theme folder as well.
Now you have just MASS added a NOINDEX / NOFOLLOW to all of your archive pages – but NOT the individual post pages themselves.
Hope this helps!
-
It should.If that does not work for some reason, try Yoast. One of these 2 plugins should be able to deindex these pages for you. I presume you are using the latest version of Wordpress as well as the Plugin.
-
hi najul.. Thanks, I already use allinone seo, and have that option selected, but it hasn't put noindex on these pages.
-
hi syed.
Thanks for the post.. I did that a couple of months ago, and it has removed the description, but the pages are still indexed. I'm trying to get them deindexed.
Thanks
-
If you use All in One SEO Plugin, you can enable a setting where you can set a Noindex on all the Archive level pages. I hope this helps.
-
I don't know of any plugin that does this but why not simply do it via robots.txt:
<code>User-agent: Googlebot Disallow: /page/specificfolder/</code>
where 'specificfolder' could be '/2/' as in your example (domain.com/page/2/) - it would simply noindex all content under that specific folder.
Also, if you want to noindex specific pages/posts, you could do it by using this plugin: http://yoast.com/wordpress/meta-robots-wordpress-plugin/
Got a burning SEO question?
Subscribe to Moz Pro to gain full access to Q&A, answer questions, and ask your own.
Browse Questions
Explore more categories
-
Moz Tools
Chat with the community about the Moz tools.
-
SEO Tactics
Discuss the SEO process with fellow marketers
-
Community
Discuss industry events, jobs, and news!
-
Digital Marketing
Chat about tactics outside of SEO
-
Research & Trends
Dive into research and trends in the search industry.
-
Support
Connect on product support and feature requests.
Related Questions
-
No: 'noindex' detected in 'robots' meta tag
Pages on my site show No: 'noindex' detected in 'robots' meta tag. However, when I inspect the pages html, it does not show noindex. In fact, it shows index, follow. Majority of pages show the error and are not indexed by Google...Not sure why this is happening. The page below in search console shows the error above...
Technical SEO | | Sean_White_Consult0 -
Will deleting Wordpress tags result in 404 errors or anything?
I want to clean up my tags and I'm worried I'm going to look in my webmasters the next day with hundreds of errors. Whats the best way of doing this?
Technical SEO | | howlusa0 -
Duplicate Titles on Wordpress blog pages
Hi, I have an issue where I am getting for duplicate page titles for pages that shouldn't exist. The issue is on the blog index page's (from 0 - 16) and involves the same set of attachment_id for each page, i.e. /blog/page/10/?attachment_id=minack /blog/page/10/?attachment_id=ponyrides /blog/page/11/?attachment_id=minack /blog/page/11/?attachment_id=ponyrides There are 6 attachment_id values (and they are not ID values either) which repeat for every page on the index now what I can't work out is where those 6 links are coming from as on the actual blog index page http://www.bosinver.co.uk/blog/page/10/ there are no links to it and the links just go to blog index page and it ignores the attachment_id value. There is no sitemap.xml file either which I thought might have contained the links. Thanks
Technical SEO | | leapSEO0 -
Will sitemap generated in Yoast for a combined wordpress/magento site map entire site ?
Hi For an ecommerce site thats been developed via a combination of wordpress and magento and has yoast installed, will the sitemap (& other yoast features) map (& apply to) the entire site or just wordpress aspects ? In other words does one need to do anything else to have a full sitemap for a combined magento/wordpress site or will Yoast cover it all ? This link seems to suggest should be fine but seeing if anyone else encountered this and had problems or if straightforward ? http://fishpig.co.uk/wordpress-integration/docs/plugins.html cheers dan
Technical SEO | | Dan-Lawrence0 -
Wordpress Redirect Plugin Vs Manual .htaccess?
Hi everyone, I need to 301 redirect my old pages to new ones but i am confused between whether to choose plugin for this or i should manually rewrite the code on .htaccess file. Please give your suggestion and if you think i should use plugin then which one?
Technical SEO | | himanshu3019890 -
Changing title tag in wordpress media pages
Hello! I have a problem of duplicate title on 59 pages in Worpress. I Guess it happened after a recent WP update, because, suddenly, I got a peak of 59 from zero in a day. The SeoMoz crawl report states that there are 59 duplicate title. As you may see in the picture those are all media pages, whose title is written really badly with the formula postname/filename/blogTitle, ending up with trunkated, too long, title tags, that result in duplicate page title. How can I simply hide these mediapages or sculpting the title tag the way I want? I am using all-in-one-seo WP plugin, which doesn't seem to provide a solution. Thank you all! DoMiSol Rossini SOwZg5C.jpg
Technical SEO | | DoMiSoL0 -
Canonical Issues with Wordpress
Hi all, I have just started using Wordpress SEO by Yoast and still having a hard time correcting my Canonical issues for all posts with a .html at the end. The pluggin allows you to add a '/' to the end for canonical issues, but just for pages, not posts. How best in Wordpress to make my post change from .html/ to .html. I really don't want to go to the hassle to make each URL a new 301 redirect in my .htaccess. I hate the .html, but if they are going to stay, how can I make sure I get the .html/ link juice back to them. Many thanks!
Technical SEO | | RunningInTheRain0 -
WordPress E-Commerce Plugin Duplicate Content Problem
I am working on a wordpress website that uses the WP E-Commerce plugin. I am using the Yoast seo plugin but not totally familiar with it. I have noticed that WP E-Commerce creates duplicate content issues. Here's an example: http://www.domain.com/parent-category/product-url-1/ is the same content as http://www.domain.com/parent-category/child-category/product-url-1/. I was wondering which of these following options are the best solution: 1. 301 redirect the multiple instances to one page
Technical SEO | | theanglemedia
2. noindex all but one instance
3. Use the canonical tag (i've used this tag before for telling SE's to use the www version of a page but not sure if it's the appropriate for this)
4. a combination of one of these 3 options? Thanks in advance!0