Override / filter Excerpt 55 chars length default

Wordpress sets a default limit of 55 characters for Excerpts.

You can override this limit by adding this code to your functions.php file in a child theme

Where to copy/paste this code?
We strongly recommend you create a child theme and add this to the Child Theme functions.php.
Download a start-up child theme here.

Remember: you shouldn’t edit the theme’s functions.php.

//Change WordPress Excerpt length
function your_excerpt_length( $length ) {
return 200;
add_filter( 'excerpt_length', 'your_excerpt_length' );

Change the 200 to whatever you need.

6 thoughts on “Override / filter Excerpt 55 chars length default”

Comments are closed.