{"id":13408,"date":"2012-01-22T22:53:22","date_gmt":"2012-01-22T22:53:22","guid":{"rendered":"https:\/\/wordpress.org\/plugins-wp\/wp-last-login\/"},"modified":"2026-05-13T17:03:32","modified_gmt":"2026-05-13T17:03:32","slug":"wp-last-login","status":"publish","type":"plugin","link":"https:\/\/wordpress.org\/plugins\/wp-last-login\/","author":8772187,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"7","stable_tag":"7","tested":"6.9.4","requires":"6.5","requires_php":"7.4","requires_plugins":null,"header_name":"WP Last Login","header_author":"Konstantin Obenland","header_description":"","assets_banners_color":"066499","last_updated":"2026-05-13 17:03:32","external_support_url":"","external_repository_url":"","donate_link":"https:\/\/www.paypal.com\/cgi-bin\/webscr?cmd=_s-xclick&hosted_button_id=K32M878XHREQC","header_plugin_uri":"http:\/\/en.wp.obenland.it\/wp-last-login\/#utm_source=wordpress&utm_medium=plugin&utm_campaign=wp-last-login","header_author_uri":"http:\/\/en.wp.obenland.it\/#utm_source=wordpress&utm_medium=plugin&utm_campaign=wp-last-login","rating":3.7,"author_block_rating":0,"active_installs":10000,"downloads":154878,"num_ratings":25,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.0":{"tag":"1.0","author":"kobenland","date":"2012-01-22 23:06:10"},"1.1.0":{"tag":"1.1.0","author":"kobenland","date":"2012-02-08 08:07:41"},"1.1.1":{"tag":"1.1.1","author":"kobenland","date":"2012-04-01 12:51:31"},"1.1.2":{"tag":"1.1.2","author":"kobenland","date":"2012-04-11 15:01:43"},"1.2.0":{"tag":"1.2.0","author":"kobenland","date":"2013-04-20 05:04:24"},"1.2.1":{"tag":"1.2.1","author":"kobenland","date":"2013-04-21 01:01:24"},"1.3.0":{"tag":"1.3.0","author":"obenland","date":"2014-09-04 15:07:29"},"1.4.0":{"tag":"1.4.0","author":"obenland","date":"2015-06-16 08:13:35"},"2":{"tag":"2","author":"obenland","date":"2017-12-22 21:40:17"},"3":{"tag":"3","author":"obenland","date":"2020-11-23 22:26:03"},"4":{"tag":"4","author":"obenland","date":"2021-07-16 04:23:45"},"5":{"tag":"5","author":"obenland","date":"2023-10-28 22:54:58"},"6":{"tag":"6","author":"obenland","date":"2023-12-22 19:44:02"},"7":{"tag":"7","author":"obenland","date":"2026-05-13 17:03:32"}},"upgrade_notice":[],"ratings":{"1":4,"2":3,"3":2,"4":3,"5":13},"assets_icons":{"icon.svg":{"filename":"icon.svg","revision":3527809,"resolution":false,"location":"assets","locale":false}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3527809,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250.png":{"filename":"banner-772x250.png","revision":3527809,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{"blueprint.json":{"filename":"blueprint.json","revision":3531236,"resolution":false,"location":"assets","locale":"","contents":"{\"landingPage\":\"\\\/wp-admin\\\/users.php\",\"preferredVersions\":{\"php\":\"8.3\",\"wp\":\"latest\"},\"steps\":[{\"step\":\"login\",\"username\":\"admin\",\"password\":\"password\"},{\"step\":\"runPHP\",\"code\":\"<?php require_once 'wordpress\\\/wp-load.php'; wp_insert_user( array( 'user_login' => 'test_subscriber' ) ); $user_id = wp_insert_user( array( 'user_login' => 'test_user' ) ); update_user_meta( 1, 'wp-last-login', time() ); update_user_meta( $user_id, 'wp-last-login', strtotime( 'yesterday' ) ); ?>\"},{\"step\":\"installPlugin\",\"pluginData\":{\"resource\":\"wordpress.org\\\/plugins\",\"slug\":\"wp-last-login\"},\"options\":{\"activate\":true}}]}"}},"all_blocks":[],"tagged_versions":null,"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":2817053,"resolution":"1","location":"assets","locale":"","width":286,"height":452}},"screenshots":{"1":"Last login column in the user table."}},"plugin_section":[],"plugin_tags":[83,60860,602,262411,2153],"plugin_category":[38],"plugin_contributors":[77566],"plugin_business_model":[],"class_list":["post-13408","plugin","type-plugin","status-publish","hentry","plugin_tags-admin","plugin_tags-last-login","plugin_tags-login","plugin_tags-login-date","plugin_tags-user","plugin_category-authentication","plugin_contributors-obenland","plugin_committers-obenland"],"banners":{"banner":"https:\/\/ps.w.org\/wp-last-login\/assets\/banner-772x250.png?rev=3527809","banner_2x":"https:\/\/ps.w.org\/wp-last-login\/assets\/banner-1544x500.png?rev=3527809","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":"https:\/\/ps.w.org\/wp-last-login\/assets\/icon.svg?rev=3527809","icon":"https:\/\/ps.w.org\/wp-last-login\/assets\/icon.svg?rev=3527809","icon_2x":false,"generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/wp-last-login\/assets\/screenshot-1.png?rev=2817053","caption":"Last login column in the user table."}],"raw_content":"<!--section=description-->\n<p><strong>WP Last Login<\/strong> records when each user signs in and surfaces it as a sortable column on the Users screen \u2014 so you can see who's active, identify dormant accounts, and confirm that real people are coming back.<\/p>\n\n<p><strong>Features<\/strong><\/p>\n\n<ul>\n<li>Sortable \"Last Login\" column on the Users screen, including the network admin user list on multisite.<\/li>\n<li>Hover any date to reveal the exact login time.<\/li>\n<li>Captures logins via the standard <code>wp_login<\/code> action, so it works with any login flow that triggers it \u2014 including the <a href=\"https:\/\/wordpress.org\/plugins\/two-factor\/\">Two Factor<\/a> plugin, WooCommerce, BuddyBoss, and most social-login plugins.<\/li>\n<li>Users without a recorded login show a neutral em-dash (\u2014) \u2014 never a misleading \"never\" \u2014 and still sort correctly when ordered by last login.<\/li>\n<li>Lightweight: one user meta key, no settings page, no extra database tables.<\/li>\n<li>Filter hooks let you customize the date format or hide the column from non-admin roles.<\/li>\n<\/ul>\n\n<h3>Plugin Filter Hooks<\/h3>\n\n<p><strong>wpll_current_user_can<\/strong> (<em>boolean<\/em>)<\/p>\n\n<blockquote>\n  <p>Whether the column is supposed to be shown.\n  Default: true<\/p>\n<\/blockquote>\n\n<p><strong>wpll_date_format<\/strong> (<em>string<\/em>)<\/p>\n\n<blockquote>\n  <p>The date format string for the date output.<\/p>\n<\/blockquote>\n\n<!--section=installation-->\n<ol>\n<li>Download WP Last Login.<\/li>\n<li>Unzip the folder into the <code>\/wp-content\/plugins\/<\/code> directory.<\/li>\n<li>Activate the plugin through the 'Plugins' menu in WordPress.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"why%20does%20the%20column%20show%20an%20em-dash%20%28%E2%80%94%29%20for%20all%20my%20users%3F\"><h3>Why does the column show an em-dash (\u2014) for all my users?<\/h3><\/dt>\n<dd><p>The plugin records a login when a user signs in <em>after<\/em> it's been activated. WordPress doesn't store historical login data, so existing accounts will start populating their \"Last Login\" the next time each user logs in. Hovering the dash shows a tooltip explaining the same.<\/p><\/dd>\n<dt id=\"how%20do%20i%20change%20the%20date%20format%20or%20show%20the%20time%3F\"><h3>How do I change the date format or show the time?<\/h3><\/dt>\n<dd><p>The date follows your site's general date format (Settings \u2192 General); the exact time appears on hover. To override the date format, use the <code>wpll_date_format<\/code> filter:<\/p>\n\n<pre><code>add_filter( 'wpll_date_format', function() {\n    return 'Y-m-d H:i';\n} );\n<\/code><\/pre><\/dd>\n<dt id=\"how%20do%20i%20hide%20the%20column%20from%20non-admin%20users%3F\"><h3>How do I hide the column from non-admin users?<\/h3><\/dt>\n<dd><p>Filter <code>wpll_current_user_can<\/code> and return a capability check. Login tracking still happens \u2014 only column visibility is gated:<\/p>\n\n<pre><code>add_filter( 'wpll_current_user_can', function() {\n    return current_user_can( 'manage_options' );\n} );\n<\/code><\/pre><\/dd>\n<dt id=\"does%20it%20work%20with%20multisite%2C%20two%20factor%2C%20woocommerce%2C%20buddyboss%2C%20or%20social%20login%20plugins%3F\"><h3>Does it work with multisite, Two Factor, WooCommerce, BuddyBoss, or social login plugins?<\/h3><\/dt>\n<dd><p>Yes. The plugin hooks into WordPress's standard <code>wp_login<\/code> action, so any login method that triggers it is captured. The Two Factor plugin (which interrupts <code>wp_login<\/code>) is supported via a dedicated hook.<\/p><\/dd>\n<dt id=\"what%20happens%20to%20my%20data%20if%20i%20deactivate%20the%20plugin%3F\"><h3>What happens to my data if I deactivate the plugin?<\/h3><\/dt>\n<dd><p>Deactivating leaves stored login timestamps intact, so reactivating preserves history. Uninstalling (deleting the plugin entirely) removes all of the plugin's user meta.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>7<\/h4>\n\n<ul>\n<li>Added compatibility with Two Factor plugin. Props @bkno.<\/li>\n<li>Improved date display to display login time on hover.<\/li>\n<\/ul>\n\n<h4>6<\/h4>\n\n<ul>\n<li>Revamped file structure to remove unnecessary files.<\/li>\n<li>Fixed a bug where login dates were overwritten on plugin reactivation. Props @richardbuff.<\/li>\n<\/ul>\n\n<h4>5<\/h4>\n\n<ul>\n<li>Improved uninstall routine (no longer queries all users).<\/li>\n<li>Updated utility class.<\/li>\n<li>Tested with WordPress 6.1.<\/li>\n<\/ul>\n\n<h4>4<\/h4>\n\n<ul>\n<li>Improved date display to account for the timezone of the site. Props @knutsp.<\/li>\n<\/ul>\n\n<h4>3<\/h4>\n\n<ul>\n<li>Fixed a bug where users who haven't logged in disappear from user lists when ordering by last login. See https:\/\/wordpress.org\/support\/topic\/new-users-dont-get-the-meta-field\/<\/li>\n<\/ul>\n\n<h4>2<\/h4>\n\n<ul>\n<li>Maintenance release.<\/li>\n<li>Updated code to adhere to WordPress Coding Standards.<\/li>\n<li>Tested with WordPress 5.0.<\/li>\n<\/ul>\n\n<h4>1.4.0<\/h4>\n\n<ul>\n<li>Fixed a long standing bug, where sorting users by last login didn't work.<\/li>\n<li>Tested with WordPress 4.3.<\/li>\n<\/ul>\n\n<h4>1.3.0<\/h4>\n\n<ul>\n<li>Maintenance release.<\/li>\n<li>Tested with WordPress 4.0.<\/li>\n<\/ul>\n\n<h4>1.2.1<\/h4>\n\n<ul>\n<li>Reverts changes to wp_login() as the second argument seems not to be set at all times.<\/li>\n<\/ul>\n\n<h4>1.2.0<\/h4>\n\n<ul>\n<li>Users are now sortable by last login!<\/li>\n<li>Updated utility class.<\/li>\n<li>Added Danish translation. Props thomasclausen.<\/li>\n<\/ul>\n\n<h4>1.1.2<\/h4>\n\n<ul>\n<li>Fixed a bug where content of other custom columns were not displayed.<\/li>\n<\/ul>\n\n<h4>1.1.1<\/h4>\n\n<ul>\n<li>Updated utility class.<\/li>\n<\/ul>\n\n<h4>1.1.0<\/h4>\n\n<ul>\n<li>Made the display of the column filterable.<\/li>\n<li>Widened the column a bit to accommodate for large date strings.<\/li>\n<\/ul>\n\n<h4>1.0<\/h4>\n\n<ul>\n<li>Initial Release.<\/li>\n<\/ul>","raw_excerpt":"Adds a sortable &quot;Last Login&quot; column to the Users screen \u2014 spot inactive accounts and see who&#039;s actually using your site.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/13408","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=13408"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/obenland"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=13408"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=13408"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=13408"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=13408"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=13408"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=13408"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}