How To Get WordPress Widget ID

In this blog post, I want to share with you, how to get the id of a WordPress widget. This is very useful when you want to customize any widget added to your WordPress website especially if you want to use media queries to control whether the widget should display only on mobile, tablet or desktop.

If you want to get the id of WordPress widget easily, I recommend you install the Get Widget ID plugin for WordPress.

By making use of this plugin, you no longer have to be inspecting elements and messing with your site html.

Simply install this plugin and you will see the widget ID been displayed on the widget form as seen in the screenshot below :


If you know other simple trick I can use to get WordPress widget ID, kindly share via comments.