How to filter your WordPress users by their online status
In this article, we are going to look into how you can use the online status of your WordPress users to search, filter, and analyze your user activity with the help of Users Insights.
There are many situations when you might need to know how many online users do you have at the moment in real-time, which specific users are online at the moment, and when was the last time a particular user was online at your WordPress site. Unfortunately, WordPress by default doesn’t provide any kind of information about the user’s online activity.
The Users Insights WordPress plugin comes with a few features out of the box that makes it easy to track user activity and find your current and recently active or inactive WordPress users in your WordPress dashboard.
Here is a short video that demonstrates the whole process of finding your online users in detail:
By knowing your WordPress users’ online activity, with the help of Users Insights, you can get instant answers to questions like:
- Which users are currently online in real-time?
- Which users show online only once and never came back?
- Which new users from the last 30 days have not been on our website more than 10 times?
- Which users signed up 60 days ago, and have logged in more than 10 times but haven’t made any purchases (in WooCommerce)?
- Which of the users that have signed up in the past 30 days has been visiting our website quite often?
- Which customers have not been active recently? When was the last time they showed up?
Finding who is currently online
Once you activate the plugin, every time a user login into your WordPress website, Users Insights will detect the online status of the user and will show a green dot next to his/her username in the Users Insights user table. This is a nice and quick way for WordPress admins to get an overview of all the online users in WordPress.
Finding the users who have been recently online
Besides the detection of the user’s online status, Users Insights also stores the last time when the user was online. This information is available under the “Last Seen” field. If you are not seeing this field in your user table you can make it visible from the “eye” menu. If you click on the heading of this column, your user list will get sorted, showing the most recently active users first and showing online users on top of the list. In this way, you can track how many users are online on your WordPress site in real-time.
Filtering your WordPress users by their online status
The last seen status is also available in the Users Insights filters. If you select the “Last Seen” field from the filter menu, you will see all the available filtering options for this field. The first option is the “last seen is less than”, which allows you to filter your WordPress users by how recently they were online.
For example, applying the filter “Last seen is less than 60 days ago” will show you all the users who have been online in the past 60 days.
The “is more than” option, on the other hand, gives you the ability to filter your users who have not been online for a specific number of days. For example, if you want to see all the users who have not been online in the last seven days you can apply the filter “last seen is more than 7 days ago”.
The “is exactly” filter works in a similar way, but it is more specific – it will show you all the users who have been online exactly 7 days ago.
The “is after” filter allows to filter the users that have been last online after a specific date. For example, if you want to see all the users who have shown up on your website after the 1st of November, you can add the filter “Last seen is after the 1st Nov 2016”.
The “is” and “is before” filters work in a similar way. With these filter, you can pick a date on or before which the users were last online respectively.
The “is set” filter will show you all the users who have any value stored in the “last seen” field of Users Insights. This filter will show you all the users that have been online since you activated Users Insights on your website.
The “is not set” filter will show you all the users whose online status was not detected. By using this filter, you can see all the users who have not been online since you activated Users Insights.
Combining the online status data with other filters
Because the Users Insights filters are stackable, you can add multiple filters at once. This means that you can combine the user’s online status data with all the other available Users Insights filters. Here is an example of a filter showing all the user’s who have been online in the last 80 days, whose location is the United States, and who have posted at least 1 comment.
Another example is finding the users that have visited once but never came back. This can be achieved by using the combination of the “Last Seen” and “Sessions” filters. As we mentioned above, by applying the “Last Seen is set” filter you can find the list of users that have been online since Users Insights was installed. Then just by applying a filter “Sessions is 1”, you can further segment the user list to show you only the users that have one session.
Conclusion
As you can see, knowing the online status of your WordPress users and having the ability to use this data to search and filter your WordPress users can be a very useful user management tool. We hope that you will find this article useful and that it is going to help you improve your WordPress user organization and management.