Embed WordPress Widget Areas/Dynamic Sidebars in posts or pages using simple shortcodes

Have you ever wished to embed some widgets into your pages/posts but could not do because you needed to write code? Today, I am going to show you something which you haven't seen before. That's right. You can embed any widget(to be specific, widget area) to any post/page  and anywhere inside the content using simple shortcode [dynamic-sidebar]

The plugin I am releasing today, I call it WordPress Widgets Shortcode. It  enables you to embed any widget area(or dynamic sidebars)  in your posts/pages anywhere using simple shortcode.

Here is the syntax

[dynamic-sidebar id='Name of your WidgetArea/Dynamic Sidebar']

I originally wrote this code for our upcoming theme(Hi Buddy) and wanted to allow site administrators to embed any widget area in posts/pages. Today, I have bundling it as a plugin to make it available to you all.


Choose any widget area and copy the name. You just need the name of the widget area/dynamic sidebar as shown below

Insert the shortcode in post and put the name as id in the shortcode as shown below

Check it out

So, all you need to know is the name of the widget area and boom!

Download & Installation:-


Bonus: If your theme has limited number of widget areas, you can use a plugin to generate as many widget area as you want. Here is a list of sidebar generators http://wordpress.org/plugins/search.php?q=sidebar+generator

I hope it will be useful for you.

Please do let me know your comments and suggestion in the comment below.

13 Responses to Embed WordPress Widget Areas/Dynamic Sidebars in posts or pages using simple shortcodes

  • @sbrajesh
    This is cool, I kinda had this idea a few years ago but you made it happen so congrats. Now if we can get a custom toolbar that spits out the notifications like facebook does. I also wanna see the private message throttling happen. I just re-released a plugin here:

    I did more work to it but it needs a dashboard setting . If you wouldn't mind playing with the code it would make a cool plugin even if its premium. I don't expect any credit, I just want to see if you can do your magic with it.

    • Hi Ben,
      Thank you. I am glad that we both thought on the same line 🙂
      Now, I am after all these plugins.
      There is something special about privacy, I had written one(as discussed on the forum) and I believe if I mix that with your code it may be something nice for everyone.
      About premium: I had to put many plugins in premium recently as I was going through financial issues. Once I come out of it(hoping to be soon as It is not much), I plan to release the free/premium in the ratio 3:1 again.
      Hope you understand.

  • Sam #

    This is a pretty useful plugin to add to my buddypress tool set! I can see it being used for a lot of my favorite widgets that could add some further practicality to my sites main content area. There are a lot of themes where this kind of functionality is built in, but being able to add it to any theme will be a huge plus. Thanks for taking the time out of your busy schedule to create this plugin Brajesh. Definitely will be getting some use out of it. 🙂
    Also, if it's not too much of a hassle, I had some questions in regards to another great plugin of yours, "Buddyblog" that I hope I could get answered. At the moment, the mod restricts all post to be viewed in the creator’s profile. Even ones created by admins in the backend of wordpress. Our site has news post that will need to be presented as a normal post on the site. Is there a way to separate user’s blog post tied to their profile (via blog category) from the normal post that will be presented on a regular post page? We're also looking for a way to adjust Buddyblog's default permalink structure. For example, a blog post titled “New Site” created by member “Bob” has a permalink structure like this by default with the plugin:
    For site structure and SEO purposes, I would rather have the blog post title in the permalinks instead of “my-posts”: Also I’m looking to change the “buddyblog” slug to just “blog” in order to integrate in the member’s blog section. The end results would look like this:
    I could go more into detail with my question through email directly if you would like. We are also willing to pay for these further functionalities if you would prefer so. If you could give me a few tips in regards to the permalink structure of buddypress, I would be tremendously grateful. 🙂
    Keep up the great work Brajesh and thanks in advance! 😀

    • Hi Sam,
      Thank you for taking time to reply. I am glad that you found it useful 🙂

      About BuddyBlog:- I have started implementing some changes in BuddyBlog to allow modifying as you want. Will have an update in 4-5 days.

      Thank You

      • Sam #

        Thanks for the response Brajesh!
        I know you’ve been busy with getting the site in order, so I appreciate all of your efforts!
        Looking forward to the updates! 😀

  • Age #

    Hi Brajesh,

    Is there code available so a widget can be called within a php file?


  • Age #

    @Brajesh, Thanks for your suggestion! Works okay.

  • @sbrajesh
    Can you please contact me via email at bphelp.1@gmail.com
    I could really use your advice! Thanks!

  • Simple and awesome plugin! saved my hours 🙂