# Stop Sticky Posts Jumping to the Top

> Keeps sticky posts in normal date order on the blog page, so you can still mark posts as sticky for other uses without changing the main feed.

- Type: PHP
- Runs: Run everywhere
- Category: [Archives](https://wpide.com/library/category/archive/)
- Tags: sticky, blog, order
- Author: WPIDE Team
- Installs: 0
- Updated: 2026-10-28
- Page: https://wpide.com/library/ignore-sticky-posts-on-blog/

## Code

```php
add_action( 'pre_get_posts', function ( $query ) {
    if ( ! is_admin() && $query->is_main_query() && $query->is_home() ) {
        $query->set( 'ignore_sticky_posts', true );
    }
} );
```

## How to use it

Install the free WPIDE plugin (https://wordpress.org/plugins/wpide/), find "Stop Sticky Posts Jumping to the Top" in its snippet library and add it in one click; or create a new PHP snippet in WPIDE (or any code snippets plugin) and paste the code above. More snippets: https://wpide.com/library/
