Title: Undefined array key &#8220;excerptLength&#8221; in wp-includes/blocks/post-excerpt.php
Last modified: February 13, 2026

---

# Undefined array key “excerptLength” in wp-includes/blocks/post-excerpt.php

 *  [eggdesign1994](https://wordpress.org/support/users/eggdesign1994/)
 * (@eggdesign1994)
 * [3 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-excerptlength-in-wp-includes-blocks-post-excerpt-php/)
 * Hi,
 * One of our sites has a couple of thousands of entries like this:
 * PHP Warning: Undefined array key “excerptLength” in /home/mondiumcom/public_html/
   wp-includes/blocks/post-excerpt.php on line 47
   We’re not using Gutenberg in the
   site at all.
 * How do we stop this error?
 * Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Lucian Padureanu](https://wordpress.org/support/users/lucianwpwhite/)
 * (@lucianwpwhite)
 * [3 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-excerptlength-in-wp-includes-blocks-post-excerpt-php/#post-18821074)
 * Hey there [@eggdesign1994](https://wordpress.org/support/users/eggdesign1994/)!
   Are you using the latest WP Core version, correct? I see a similar bug reported
   almost 2yr ago, after doing some research, and[ I think this was reported as part of another ticket](https://github.com/WordPress/gutenberg/issues/62763)
   and under a different format, but it’s still not fixed unfortunately..
 *  Moderator [threadi](https://wordpress.org/support/users/threadi/)
 * (@threadi)
 * [3 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-excerptlength-in-wp-includes-blocks-post-excerpt-php/#post-18821127)
 * I’m not sure if these are comparable messages. I haven’t seen this in any project
   myself. First of all, these are not errors but warnings because a value is missing.
   There can be many reasons for this, including plugins you use calling the component
   and not passing on everything that is necessary. You may not be aware of this,
   but plugins could do this. Themes as well.
 * Since we don’t know your project, we can’t say anything more specific. One recommendation
   would be to deactivate all plugins on a trial basis and see if it stops. If so,
   it was one of the plugins. If not, try changing the theme as well.

Viewing 2 replies - 1 through 2 (of 2 total)

You must be [logged in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fundefined-array-key-excerptlength-in-wp-includes-blocks-post-excerpt-php%2F%3Foutput_format%3Dmd&locale=en_US)
to reply to this topic.

## Tags

 * [block](https://wordpress.org/support/topic-tag/block/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 3 participants
 * Last reply from: [threadi](https://wordpress.org/support/users/threadi/)
 * Last activity: [3 months, 3 weeks ago](https://wordpress.org/support/topic/undefined-array-key-excerptlength-in-wp-includes-blocks-post-excerpt-php/#post-18821127)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
