Title: Escaping shortcode
Last modified: August 19, 2016

---

# Escaping shortcode

 *  Resolved [splotch](https://wordpress.org/support/users/splotch/)
 * (@splotch)
 * [18 years ago](https://wordpress.org/support/topic/escaping-shortcode/)
 * How do you escape shortcode in the post content? I’ve searched all over the site
   and can’t seem to find it documented.
 * I’m trying to document a plugin and I need to be able to show the shortcode in
   the post as it should be written, not have it replaced by my plugin.
 * I know it’s a simple solution, I just can’t find what it is.
 * Thanks for your help.

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

 *  Thread Starter [splotch](https://wordpress.org/support/users/splotch/)
 * (@splotch)
 * [18 years ago](https://wordpress.org/support/topic/escaping-shortcode/#post-760621)
 * Apparently not too many people know how to escape shortcodes in a post. If anyone
   does know, please post it. I’m sure I’m not the only person looking for this.
 *  Thread Starter [splotch](https://wordpress.org/support/users/splotch/)
 * (@splotch)
 * [18 years ago](https://wordpress.org/support/topic/escaping-shortcode/#post-760694)
 * I think I’ve finally dug up the solution. Instead of using the “[” and “]” characters,
   replace them with their respective html entity counterparts.
 *     ```
       &#91; => [
       &#93; => ]
       ```
   
 * Hope that helps anyone else out there banging their head on the same problem.
 *  Thread Starter [splotch](https://wordpress.org/support/users/splotch/)
 * (@splotch)
 * [18 years ago](https://wordpress.org/support/topic/escaping-shortcode/#post-760730)
 * Be careful switching between the Visual and HTML editors, as this will revert
   the `[` to `[` and cause your shortcode to be parsed.
 *  [John Blackbourn](https://wordpress.org/support/users/johnbillion/)
 * (@johnbillion)
 * WordPress Core Developer
 * [17 years, 4 months ago](https://wordpress.org/support/topic/escaping-shortcode/#post-760849)
 * Nice info Splotch! Thanks for sharing.

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

The topic ‘Escaping shortcode’ is closed to new replies.

## Tags

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

 * 4 replies
 * 2 participants
 * Last reply from: [John Blackbourn](https://wordpress.org/support/users/johnbillion/)
 * Last activity: [17 years, 4 months ago](https://wordpress.org/support/topic/escaping-shortcode/#post-760849)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
