# Add a "Continue Reading" Link to Excerpts

> Replaces the [...] at the end of automatic excerpts with an accessible "Continue reading" link to the full post.

- Type: PHP
- Runs: Run everywhere
- Category: [Content](https://wpide.com/library/category/content/)
- Tags: content, excerpt, read-more
- Author: WPIDE Team
- Installs: 0
- Updated: 2026-10-28
- Page: https://wpide.com/library/excerpt-read-more-link/

## Code

```php
add_filter( 'excerpt_more', function () {
    if ( is_admin() ) {
        return ' &hellip;';
    }

    return sprintf(
        ' &hellip; <a class="read-more" href="%1$s">Continue reading<span class="screen-reader-text"> %2$s</span></a>',
        esc_url( get_permalink() ),
        esc_html( get_the_title() )
    );
}, 999 );
```

## How to use it

Install the free WPIDE plugin (https://wordpress.org/plugins/wpide/), find "Add a "Continue Reading" Link to Excerpts" 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/
