WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm well aware that WordPress by default does not process shortcodes in the sidebar. My question is why.

I'm building a very small plugin that exports some content when the shortcode is present. This will be primarily used in the content area. I want to allow the user to display that content in the sidebar and I'm debating including the one line fix to enable the shortcodes rather than adding ~50 lines of code to create a widget.

Is there something going on under the hood that is a good reason to avoid the shortcode in the sidebar? Is it simply a convention?

share|improve this question

There are a few pitfalls, mainly with wpautop being applied after the shortcode filter, and multiple do_shortcode calls because of plugins that already added this filter to widget_text.

See the discussion in the following ticket: http://core.trac.wordpress.org/ticket/10457

share|improve this answer
this is awesome information! Thanks. – BFTrick Oct 2 '12 at 13:26

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.