Black Friday 40% off yearly and lifetime plans · 18d left Ends in 18d09h23m Claim 40% off
Security38 docs

How to Hide the Remember Me Checkbox in WordPress

Hide the Remember Me checkbox on the WordPress login form. Forces all logins to expire at the end of the session, improving security for shared or public computers.

By Founder & Lead Developer

Last updated

2 minutes

Key takeaways

  • Single toggle, no nested options
  • Removes the “Remember Me” checkbox from the login form
  • All sessions expire when the browser closes
  • Pairs well with the [Auto Logout](security-auto-logout.md) feature
  • Use this for high-security sites where long sessions are a concern

What Is the Hide Remember Me Checkbox feature?

By default, the WordPress login form has a “Remember Me” checkbox. When checked, the user’s session persists for 14 days (even if the browser is closed). When unchecked, the session expires when the browser closes.

The Hide Remember Me Checkbox feature removes this checkbox from the login form, forcing all sessions to expire at browser close.

Why You Need It

Long sessions are convenient but create security risks:

  • Shared computers: An admin who forgets to log out leaves a persistent session
  • Lost or stolen devices: A 14-day session is still valid even after the device is gone
  • Public computers: Anyone using the computer after the admin can stay logged in

For high-security sites, forcing session expiry at browser close is a critical hardening step.

How to Hide the Remember Me Checkbox in WordPress

  1. Step 1

    Navigate to Settings

    Click into the Classic Monks plugin settings in your WordPress dashboard.

  2. Step 2

    Go to the Security Tab

    Click on the Security menu, then click the WP Protection subtab.

  3. Step 3

    Enable Hide Remember Me Checkbox

    Scroll to Hide Remember Me Checkbox and toggle on.

    Hide remember me checkbox

  4. Step 4

    Save Changes

    Click Save Changes.

  5. Step 5

    Test

    Log out. Visit the login form. The “Remember Me” checkbox should not be visible.

Configuration Options

Option Description Default
Hide Remember Me Checkbox Master toggle. Off

No nested options.

What Gets Affected

  • The login form: the “Remember Me” checkbox is removed
  • The user sessions: all sessions expire when the browser closes
  • The default session duration: changed from 14 days to “session” (browser close)

What Does NOT Get Affected

  • The wp-admin: not affected (after login)
  • The user experience: users don’t notice the difference unless they try to stay logged in
  • The custom login forms: not affected (only the default WordPress login form)
  • The remember me functionality: still works if the user manually sets the cookie (not via the checkbox)

Advanced Options (Developers)

This feature registers 1 WordPress hook in security-functions.php:

Actions:

  • login_head calls cm_hide_remember_me() (Hides Remember Me checkbox via CSS)
// Hooked in security-functions.php
add_action( 'login_head', 'cm_hide_remember_me' );

The feature modifies WordPress behavior by registering or removing hooks. Disabling it reverses those changes and WordPress returns to its default behavior.

Troubleshooting

4 problems and how to fix each one.

The Remember Me checkbox is still showing

Cause: The toggle is off, or a custom login form is being used.
Fix: Verify the toggle is on. The feature only affects the default WordPress login form (wp-login.php). Custom login forms (e.g., WooCommerce’s login) are not affected.

Users are being logged out too frequently

Cause: The session is now expiring at browser close, which is more frequent than the default 14-day remember me.
Fix: This is the expected behavior of the feature. If you need longer sessions, use the Stay Logged In feature (see related articles) which adds a “stay logged in” checkbox that can be configured for longer sessions.

The custom login form is not affected

Cause: The Hide Remember Me feature only affects the default WordPress login form.
Fix: If you use a custom login form (e.g., WooCommerce, a custom theme login), use the login_form action to remove the checkbox from the custom form. Or use a CSS selector to hide it.

The session is still 14 days

Cause: A caching plugin or another plugin is setting the auth cookie duration.
Fix: Check for plugins that override the auth cookie duration. Use the auth_cookie_expiration filter to set a custom duration.

Was this doc helpful?

Your answer tells us which docs to fix first.

Still stuck? Ask on the forum or email help@classicmonks.com.
Joy Chetry
Written by the person who built it

Joy Chetry

Founder & Lead Developer, Classic Monks

Joy is the founder of Classic Monks and GoodMonks Solutions, a web development agency that builds WordPress and WooCommerce sites for clients. Classic Monks grew out of the agency's own need to consolidate 20 to 30 separate plugins into one core stack.

Follow this doc on a real site.

Open a private WordPress site with Classic Monks, WooCommerce and Bricks Builder installed, and follow this doc step by step. Free for 24 hours, no card.

280 docs, written by Joy Chetry 15 day refund window