How to Display the most recently added products first in magento

Magento Provides three different options to sort the catalog products i.e
name, price, position. For a store with more than 1000 products it is not
possible enter position values in backend for each products. We can replace
this with product ids , so that the frontend will display the most recently
added products.

Step 1: To Achieve this copy the file Toolbar.php from app/code/core/Mage/Catalog/Block/Product/List/Toolbar.php. Create a Directory Structure in local and paste the Toolbar.php
as shown below

Step 2: Around line 232 you should see the below code in setCollection

Replace the above code with the new code given below

Now the newly added products will be displayed first in your magento store.

Compatability: Magento 1.6

  1. Ulrik says:

    I have long tried all sorts of tips and tricks to show the latest added products first, but this worked first time …

    Thanks Ramesh,

  2. Tabrez says:

    Hi Ramesh,

    My name is Tabrez and also want to achieve something like that functionality in So it is possible in this case. and how can i set the limit of product in recently added products.

    Any suggestions are most welcome šŸ™‚


  3. DOJ says:

    Just to say, you just saved me from hours of agony and the brink of defeat with regards to this. You’re a king among kings and I have unconditional love for you.

    Synopsis for others: Upgraded from to and all product ordering was randomised on the frontend and all category positions set to ‘1’ in the back end. Even when I manually reordered hundreds of items, adding a new product would inexplicably appear in the second slot on the frontend instead of the first (top left of the layout.)

    After tearing my hair out, this instantly fixed it, and saved me manually re-numbering thousands of items. Wish I had found this post 24 hours ago.

    Thank you!

  4. crack97 says:

    Am using This method showed the recently added products, but after one second, it reverts to show the old products at the top, any solution?

    • Ramesh says:

      This tutorial was written with version, not sure of the behaviour of there may be some cache problems please clear your cache and check.

  5. Carol says:

    Hi, I might not be able to comment on the code, to me it is easier to just
    use tested extensions. I saw an interesting solution recently – a private sale script from Plumrocket. A number of magento extensions and magento private sales theme. Maybe you’ll find it valuable for yourself. I think you can find it on their site.

  6. thanks, it works like a charm, thumbs up 4U

  7. tushartajane says:

    Supercool. Thanks & Cheers

Leave a Comment

Your email address will not be published. Required fields are marked *