A shortcode is a small piece of bracketed code — like `` or `
Error: Contact form not found.
` — that WordPress automatically converts into more complex functionality when a page or post is actually displayed. It's a longstanding way to add dynamic elements without writing raw HTML or PHP directly.Common Built-in WordPress Shortcodes
- `` — displays an image gallery
- `` — adds a caption to an embedded image
- `` — embeds external content, such as a video
Plugin-Provided Shortcodes
Many plugins add their own custom shortcodes — a contact form plugin might use `
Error: Contact form not found.
` to display a specific form, while a WooCommerce shortcode could display a product grid or a shopping cart, anywhere the shortcode is placed.Shortcodes vs. Gutenberg Blocks
Gutenberg's visual block system has largely replaced the need for many older shortcodes, though shortcodes remain fully supported and are still widely used, particularly by plugins developed before the block editor's introduction.
Using a Shortcode
Simply typing or pasting a shortcode, like ``, directly into a post or page's content will render the corresponding functionality when the page is viewed — no additional plugin activation is needed beyond whatever plugin originally registered that specific shortcode.
« Back to Index