How to remove Date stamp from Google SERP description?

Some of you may have noticed that when your blog (or individual post) is listed on Google search results (SERPs), a date stamp gets prepended to the meta description of the indexed page (see the image below). There are are various theories regarding how and from where Google picks this date stamp. Some believe that it is the time stamp of the last post on your blog, where as a few others believe that it’s the date on which your site is last indexed. Regardless of the reason, sometimes this extra date field can be a bit annoying for some of you and in this post let me explain how you can remove the same.

Ways to remove date from search results

First of all, let me tell you that not every blogger or webmaster face this issue. And this doesn’t quite depend on your blog theme as well – i.e. Blogs using the same theme and layout may or may not have this issue. However, for those who have completely disabled post dates, this may not happen at all. And hence the fixing process starts based on that behavior because in most cases, Google seems to pick the date from the content of the page or your blog post.

Date in search result meta description

There are basically two ways of removing this date in the Google search result or meta description.

1. Use image based dates instead of the usual theme (PHP) generated server side time stamp. In this case, you have to convert the date string to images and hence it may not be very easy to create the image styles that exactly match your theme. Also, you may have to change it every time you change your styles.

2. Use client side logic (javascript) to render the dates so that when Google picks the page, it doesn’t quite read whatever (date) is there between the script tags. I prefer this method.

(Third option obviously is to remove the dates totally but you might want your post dates to be present there)

So how do we fix it? Just follow the simple steps as given below for a WordPress blog. For any other blog platform/website, you may similar logic.

– Open your theme’s index.php file.
– Search for the place where you display the time – usually a call to something like the_time(‘F j, Y’) method
– Replace that logic with Javascript. i.e. paste the following code instead of the time (Please type in the code as I have actually pasted an image of the code snippet here)

javascript to remove date from Google indexing

This makes sure that the server side date rendering is avoided and hence Google wouldn’t list it next time it index your blog’s home page.

If you want to do the same for individual posts, repeat the above step for your single.php file. Please note that existing posts may take some time before the date from their description field is removed. To enforce the changes, you may want to republish the post as well.

Update: Aug 15
Sometimes the above script still doesn’t work on single posts. In that case you may use a combination of javascript and PHP to render your date, as mentioned in the example below.

javascript and PHP to remove date from Google indexing
[Click image to enlarge]

Pros and cons of the date stamp on Meta description

If you are a regular blogger who makes one post (or more) a day, you may not really mind having a date prefixed on search results of your homepage. However, if you post once a week or so, like me, you may not want to show that your last update was a week back because it may affect your click-through rate from search. The same logic is applicable for individual posts as well. I mean, nobody will click a SERP link, if the post date/year shows something like 2008.

Also, the date prefix sometimes affects the readability of your page description (usually the marketing punchline) and at times truncates it as well.

Hope this tip was useful for your blog’s SEO!

Happy SEO!


  1. Why not just remove the date code altogether? I removed my “” code and poof, date is gone. Any thoughts?

  2. hello Ajith

    i was trying it but i get a parse error when i do that.

    the code used for the index makes no parse error, but the date is not shown on any post summary on the index page.

    and the one used for the single post has parsing error.

    i also dont know if it worked, how much time i need to test that?

    im using wordpress 3.2.1

  3. Hi
    i am using twentyten theme, where can i find this peace of code to replace.


  4. my site ( has a really old date in the search results (2004) for keyphrase ‘transformers toys’. I don’t have any text ‘2004’ anywhere in my index page.

    I’ve completely re-designed my site, altered the index page, have dynamically changing content, and a ‘latest update’ note that is always at most 2 weeks old…what am I doing here to make google show such an old date?

    • @Matt,
      Google is taking it from your home page text => “03/30/04 – The Energon section has been updated with a sleek new look and crystal-clear images!”

      Try to rephrase it without all numbers in the date – Something like on ‘Energon section was updated during first quarter (Mar 30) of 2004’, if that’s what you meant.

      Google seem to treat it like a time stamped newslog on your site.

  5. My homepage doesnt have this date, but all my other pages have a date in the SERP. How to delete these? It are all pages, not blogposts..

    • I checked your site. Google seems to be treating it like a news site and taking the date (8 nov for now) from your “Laatste nieuws” section. Try removing that widget, and probably after another page addition, everything should go.

  6. Thanks, I deleted that widget/block and now its all good, thanks a lot Ajith!

  7. Hi Ajith,

    I tried your suggestions in your main post but the sections arnt included in my theme page.php

    My homepage does not have a date on SERP but all other pages do – any idea how to remove this?

    • I checked your site. The date on sub-pages seems to be originating from your ‘Company News’ footer widget. Either remove that widget or you have to change the part where it’s rendering the date. i.e. change that part of the date to javascript based date. Once it’s corrected and by the time you submit the next news, the dates should go off I believe.

  8. Thanks Ajith,

    The news section is not a widget some I have the option of either removing it or change the part where the date is rendering (I am struggling to find this so far) but will let you know the outcome.

  9. After months searching and investigating for a possible solution for time stamp from commentaries, I finally gave up. If you hide it with javascript or any other trick, Google will display the first date that it find or register. If your posts don’t have any date, in SERP will be displayed the Google’s indexation date. Matt Cutts explains it clearly in this video:

    And I am almost sure that triying to fool Google bot with this kind of tricks could, at the end, seriously damage your pagerank. After all, hiding the date to bots but showing it to readers is a kind of cloacking, which is a black-hat seo techinque penalized by Google. And since Google is able to read javascritp code, it’s for sure it can detect and mark the trick.

    My advice is don’t use this kind of tricks. I tried this one for three months and, in that period, I couldn’t boost my pages to first place on SERPs. But since I stopped to use it, my site ( gone rapidly to top. All my snippets in the first place shows, however, the time stamp. You can check it for yourselves here, here or here.

    Hope this could help

    • Ego, It’s not a blackhat technique. We produce content and we can decide whether it has to be date-stamped. I wouldn’t like Google putting a timestamp on my valuable description text anyhow.

  10. Of course it is a blackhat seo technique, and its name is cloacking. Your decision of google not to date-stamp your site’s SERP snippet works (when it does) thanks to hiding content to google bot, which is precisely the definition of cloaking… Take a look at Matt Cutts again:

    • If you think like that even the usage of Javascript itself is black hat. C’mon, the bots needn’t worry about what’s going to show to the webbrowser that varies hugely in terms of technology and devices where as bots are in the same old text world. We are NOT cloaking a link here nor are we embedding keywords and hence I would think that it’s a safe approach. Anyhow, there are n number of things that the dumb bots don’t see or ignore – including flash content, javascript, activex content etc.

      By the way though Google is the leading search engine, they are just one of them 🙂 The game can change anytime going forward.

      • It seems I didn’t made myself clear. I do not think that the usage of javascript is a black hat seo technique. As I said repeatidly, showing one thing to search bots (a post without date) and another one to readers (the publication’s date) is cloacking, using javascript or another resource. In other words, you can do cloacking with javascript (like in this case), but not all use o javascript is cloacking. Only the javascript used to show one thing to bots and another one to people is cloacking.

        Cloacking is simply to show one content to bots and other one to human. So, when you says you’re not cloacking because aren’t hidden a link or embedding a keyword, you’re not demostrating that this trick is not cloacking. And, of course, it’s not true that the “dumbs bot” don’t see javascript. Google bot reads javascript since 2009.

        And, finally, maybe it’s me, but it really seems unnecesary and a little bit trivial the mention of google as a non-just-one-and-only search engine… Of course Google is just one of many search engines. But this post is about (and I quote the title) “…to remove Date stamp from Google SERP…” snippet. In this context, does the other search engines really matter here?

        • Thanks for your views.

          Btw, ‘Google is just one’ comment was in the context of the unfair terms they are setting for webmasters.

          (Of course, the article is dedicated to Google SERP dates alone)

      • One more thing… Here’s Matt Cutts’ video explaining what is cloaking:

  11. Hello,
    Thank you for this helpful information. I am trying to figure out where google is pulling the date stamp for my site

    When searching for african art, the date stamp says Nov. 11, 2010. Do you have any idea where this date is coming from? Your help would be greatly appreciated.

  12. Is removing date stamp from google can be any penalty? I mean suppose I posted a content and a next day another website posted same thing then how google can make distinguish from both in absence of date mark?

    please tell me side effect if this..

  13. thanks for the post, really I had not realized how important it was far to me personally I like to publish once a week, but I think my view is important not to have that date as say they will not read things that are of 2008. : D

  14. how to remove in joomla

  15. Thanks for this Ajith. For my purposes, this was a lifesaver on one of my new sites. Anyways, I’d just like to share something, in case it may help others.

    I was getting an error with your code:

    Upon closer inspection of the original line, it was quickly remedied with a minor change:

    *default usage is

    Also, some themes work with loop.php, this is where you may need to insert/edit the code. Other themes use different methods, but you sometimes simply use document.write(‘'); and might work. It worked with some themes, not with others. Be sure to backup the file before making changes.

  16. I have a lot of posts, and I am using a theme, Yalin. The date comes in on google serps which is definitely not good, my views are okay but I believe this may be a big factor. Basically, I am not sure how to implement the code. In my single.php the code is different, would I replace the entire div, or how can I go about this? If you dont mind taking a look my Site is

    Thanks for your help.

    • Ashley, without knowing how your single.php looks like, I won’t be able to comment. Essentially, you won’t be needed to remove/replace HTML elements such as div or span but only change the PHP part/function that renders date.

  17. Hi Ajith Edassery,
    I am using smartline theme in blog. I want to remove the date from google snippet but the code the_time(‘F j, Y’ is seeing there in index.php. Please help me..

  18. Robert Rigsby :

    Thanks for this Ajith, I hated seeing the date in google search results, I thought I couldn’t get rid of it but have now. Thanks again

  19. Hi Ajith,

    thanks for your informative article. This is really useful since I am using wordpress. However, I will like to know instead of the above 2 methods, is there any ways to tell google that it is a business site, instead of a blog site on wordpress.

    Thanks and Regards.

  20. Hi, I want to remove dates from search engine result pages.
    Dates are appearing in all posts and pages please provide step by step process to remove the dates from meta description.

Leave a Reply to Ajith Prasad Edassery Cancel reply