Tutorials Web Development

The Easiest Way to Add Shortcodes to a WordPress Sidebar?

5/5 (6)

In today's WordPress hack we're going to show you how to add shortcodes to your WordPress sidebar. You can display anything like WooCommerce product list, post grid, follow us buttons or contact form via shortcode.

Let’s take the contact form as an example. To display it in any of your widget areas you need to open it’s settings and copy the shortcode itself.

add-shortcode-in-sidebar-wordpress


Go to Appearance -> Widgets and find Text widget among available widgets on the left. Drag it to the needed widget area and drop it there.

add-shortcode-in-sidebar-wordpress


Paste the shortcode into the Text widget’s content section and give it a name if you want to. Save the changes.

add-shortcode-in-sidebar-wordpress


When done, you can check the page with the widget area you put the text widget into. The shortcode will display there.

add-shortcode-in-sidebar-wordpress


That wasn’t hard at all, was it? Now feel free to go ahead and check our WordPress themes library here.


Subscribe to our daily WordPress hack-o-letter!

Don't miss your next WP Hack