Fetching Active Install Count from the Plugins API

Today the wordpress.org plugins api got a small update. With the addition of the new Active Install metric a few weeks ago, now you can get the install count from the API for use in your own projects.

For example: Popup Maker currently has [plugin_install_count plugin=”popup-maker”]+ Active Installs

Here is a simple function that will grab the count and return it.

If you want to use it be sure to cache the value, best done using the transients api. Here is an example shortcode that can be used on the front end of your website to show the count. This is the exact code used above to display the current count for Popup Maker.

Feel free to customize this to your needs.

Daniel Iser is a professional WordPress plugin developer, and the author of plugins such as Easy Modal & Popup Maker. Founder of Wizard Internet Solutions he has been working with WordPress for over 7 years creating websites and tools for clients & blog authors.

Follow on:

Leave a Comment





This site uses Akismet to reduce spam. Learn how your comment data is processed.