=== Magic Link - Secure one click passwordless login ===
Contributors: kaizencoders, mikeatkaizencoders
Donate link: https://kaizencoders.com
Tags: login, magic login, passwordless login, one click login, email login
Requires at least: 6.7
Tested up to: 6.9
Stable tag: 1.6.0
License: GPLv3 or later
License URI: http://www.gnu.org/licenses/gpl-3.0.html

Secure one click passwordless login

== Description ==

Say goodbye to forgotten passwords. Enable a secure, passwordless login experience for your WordPress site using email, SMS, or QR code magic links.

**Magic Link** makes traditional passwords a thing of the past. Instead of logging in with a username and password, users can log in simply by clicking a secure link sent to their email or phone. It’s quick, safe, and incredibly user-friendly.

Perfect for membership sites, WooCommerce stores, community forums, or any site that wants to simplify user authentication.

**Core Benefits**

> 👉 **Passwordless Login**
> No more password resets or weak password risks.

> 👉 **Email Magic Links**
> A unique, expirable login link is emailed to users.

> 👉 **Force Magic Link Login**
> Option to set Magic Link the default login method.

> 👉 **Auto-login Links**
> Automatically log in users via links in notification emails for quicker actions.

> 👉 **User-Friendly UX**
> Especially helpful for non-technical users or mobile-first visitors.

> 👉 **Redirect After Login**
> Send users to a specific page after they log in.

> 👉 **Create Magic Link for any user**
> Admin can create Magic Link for any user.

> 👉 **List All Magic Links**
> Admin can view all generated Magic Links.

> 👉 **Bulk Delete Magic Links**
> Select multiple Magic Links and delete in bulk.

> 👉 **Shortcode Support**
> Add magic link login forms anywhere on your site with `[magic-link]`.

> 👉 **Customizable Expiry**
> Set how long magic links remain valid (minutes, hours, days).

> 👉**CLI Ready**
> Control plugin settings and features via WP-CLI.

> 👉 **Fully Configurable [Coming Soon]**
> Export/import/reset settings with ease.

> 👉 **GDPR Compliant**
> No personal data is stored beyond what WordPress already collects.

**🔐 Pro Features**

> 👉 **Login URL Redirection**
> Redirect users to specific pages after login

> 👉 **Role based redirection**
> Redirect users to specific pages after login

> 👉 **Login Attempt Limits**
> Set limits on magic link generation

> 👉 **Custom Email Templates**
> Customize email design and content.

> 👉 **Improved Security**
> Avoid brute-force attacks and phishing risks related to password use.

> 👉 **IP Control**
> Enhance the security by restricting users to login from the same IP address that requested the link.

> 👉 **Login Request Throttling**
> Limit login URL generation for the given time span.

> 👉 **Brute Force Protection**
> Limit rate of login attempts and block IP temporarily.

> 👉 **Domain Restriction**
> Restrict email domains that can use the magic link login feature.

> 👉 **Trusted Domains**
> Allow users with email addresses from specified trusted domains to receive Magic Links even if they don't have a user account on the site.

> 👉 **Bulk Actions: Expire, Used Links**
> Mark Magic Links as `Expired`, `Used` in bulk.

> 👉 **Support `{magic-link}` merge tag**
> One can use `{magic-link}` merge tag in outgoing emails to auto generate Magic Link for the recipient. Useful for quick checkout, quick access to courses and other usecases where login is required.

> 👉 **REST API**
> Generate, look up, and revoke magic links from your own app, mobile client, or automation tool. Secured with WordPress application passwords.

> 👉 **Outbound Webhooks**
> Get a signed HTTP callback whenever a magic link is generated, sent, opened, used, expired, or revoked. Connect to Zapier, n8n, or your own service. Manage endpoints from **Magic Link → Webhooks** with a built-in Test Fire button.

> 👉 **SMS Magic Links [Coming Soon]**
> Send login links via SMS text messages.

> 👉 **QR Code Login [Coming Soon]**
Generate QR codes for easy mobile login.

> 👉 **Device Restrictions [Coming Soon]**
> Limit logins to specific devices/browsers.

> 👉 **Role-Based Access [Coming Soon]**
> Control which user roles can use magic links.

> 👉 **Analytics & Reporting [Coming Soon]**
> Track magic link usage and patterns.

> 👉 **Priority Support**
> Get expert help when you need it.

== Integrations ==

> 👉 **WooCommerce Integration**
> Seamless checkout experience for returning customers.

== How It Works ==

1. A user enters their email address on the login screen.
2. A one-time, time-sensitive login link is emailed to them.
3. They click the link and are instantly logged into your site — no password needed!

=== Translations ===

Does Magic Link speak your language? If not, [translate “Magic Link” into your language](https://translate.wordpress.org/projects/wp-plugins/magic-link/).

=== DO YOU HAVE ANY QUESTIONS/ FEEDBACK/ FEATURE REQUEST/ BUG REPORT❓===

Feel free to create a ticket [here](https://wordpress.org/support/plugin/magic-link/). We love to communicate with you and reply to all your queries.

=== Spread The Word ❤️ ===

If you like Magic Link, please leave us a [⭐⭐⭐⭐⭐](https://wordpress.org/support/plugin/magic-link/reviews/#new-post) review and also spread the word about it via Facebook and Twitter. That helps fellow website owners assess Social Linkz easily and benefit from it!

=== What's Next ===

If you like this plugin then consider checking out our other solutions:

[URL Shortify](https://wordpress.org/plugins/url-shortify/) - Simple, Powerful, and Easy URL Shortener Plugin For WordPress.

> URL Shortify helps you beautify, manage, and share any URL on or off of your WordPress website. Create links that look how you want using your domain name! It’s a Simple, Easy & Elegant self hosted alternative to Bitly, TinyURL, Cuttly, Pretty Links, URL Shortener By My Theme Shop, Rebrandly, BL.Link, Short.io, and many other SaaS URL Shortener services.

[Update URLs](https://wordpress.org/plugins/update-urls/) - Quick and Easy way to search old links and replace them with new links in WordPress.

> If you move your WordPress website to a new domain name, you will find that internal links to pages and references to images are not updated. Instead, these links and references will point to your old domain name. Update URLs fixes that problem by helping you change old urls and links in your website.

[Logify](https://wordpress.org/plugins/logify/)

> Logify is a comprehensive logging and monitoring plugin for WordPress that helps you keep track of various activities and events on your website. It provides detailed logs of user actions, system events, and errors, allowing you to monitor and troubleshoot your site effectively.

[Social Linkz](https://wordpress.org/plugins/social-linkz/) - Lightweight and fast social media sharing plugin

[UtilityKit](https://wordpress.org/plugins/utility-kit/)

> UtilityKit is a powerful and versatile WordPress plugin that provides a collection of essential tools and features to enhance your website's functionality. It includes a variety of utilities such as show/hide admin bar, disable comments, enable/disable WordPress debug log and see logs inside WordPress admin and many more.  All designed to improve user experience and streamline website management.
> It’s a simple & neat plugin which helps you to customize your WordPress setup in a very elegant way.

== Installation ==

**The easy way..**

1. Go to WordPress Dashboard. Locate Plugins -> Add New
2. Search **Magic Link** plugin using the search option
3. Find the plugin and click Install Now button
4. After installation, click on Activate Plugin link to activate the plugin.

**The hard way..**

1. Download the plugin [magic-link.zip](https://downloads.wordpress.org/plugins/magic-link.zip)
2. Go to WordPress Dashboard. Locate Plugins -> Add New
3. Click on the Upload Plugin link from the top
4. Upload the downloaded **magic-link.zip** file and click on Install Now
5. After installation, click on Activate Plugin link to activate the plugin.

== Frequently Asked Questions ==

= 1. Do I need any third-party services to generate Magic Link? =

No. You don't need it. Magic Link plugin generates Magic Link with your own domain.

= 2. Do I need to buy PRO to generate Magic Links?

No. You don't need to buy PRO. You can generate Magic Links with the free version of the plugin. However, PRO version has more advanced features. Check out the [feature comparison table](https://kaizencoders.com/magic-link/#pricing) for more details.

= 3. Can I use Magic Link with custom login pages? =

Yes. You can use Magic Link with custom login pages. Just add the `[magic-link]` shortcode to your custom login page.

= 4. Can I use Magic Link with WooCommerce? =

Yes. you can use Magic Link with WooCommerce. We are working on adding WooCommerce specific features in the PRO version.

= 5. Is Magic Link secure? =

Yes. Magic Link is secure. The magic links are time-sensitive and can be used for defined number of times. You can also set the expiration time for the magic links.

= 6. Can I customize the email template? =

Yes. You can customize the email template from the plugin settings page in Magic Link PRO version.

= 7. Can I use Magic Link with other plugins? =

Yes. Magic Link is compatible with most of the popular plugins. However, if you face any issues, please create a support ticket [here](https://wordpress.org/support/plugin/magic-link/).

= 8. How can I get support? =

You can get support by creating a support ticket [here](https://wordpress.org/support/plugin/magic-link/). We will try to respond to your queries as soon as possible.

= 9. Is Magic Link login force used for all users? =

No. Default login (username & password) will continue to work as it is. You can enable/disable force Magic Link login from the plugin settings page to set as default login method.

= 10. Can I use Magic Link with custom user roles? =

Yes. You can use Magic Link with custom user roles. You can also restrict Magic Link usage to specific user roles in the **PRO** version.

= 11. Can I use Magic Link with multisite? =

Yes. Magic Link is compatible with WordPress multisite.

= 12. Can we integrate Magic Link with other plugins? =

Yes. We have provided various hooks and filters to integrate Magic Link with other plugins. You can check the documentation for more details.

= 13. How to generate Magic Link for a user via WP-CLI? =

You can use the following command to generate Magic Link for a user via WP-CLI:

```wp magic-link generate <user-email>
```
Replace `<user-email>` with the email address of the user for whom you want to generate the Magic Link.

== Screenshots ==

1. Magic Link login via login screen
2. Magic Link email
3. General Settings
4. Customise Magic Link Email Subject & Message **PRO**
5. Role based login redirect **PRO**
6. Domain Restriction **PRO**
7. IP Control, Brute Force Protection & Login Request Throttling **PRO**
8. Magic Link lists
9. Magic Link Dashboard
10. Email Digest Settings
11. Email Digest Preview

== Upgrade Notice ==

= 1.6.0 =

* Adds a REST API (kc-ml/v1), HMAC-signed outbound webhooks with a full admin UI, and a fix for the Email Digest test email. Check `https://kaizencoders.com/docs/magic-link/changelog` for more details.

== Changelog ==

= 1.6.0 =

* New: REST API. **PRO**
* New: Outbound Webhooks with admin UI and Test Fire. **PRO**
* Fix: Email Digest test email not sending issue.

= 1.5.0 =

* New: Audit Log. Every magic-link lifecycle event (generated, sent, opened, used, expired, revoked, failed) is recorded in a new `wp_kc_ml_audit_log` table and viewable under Magic Link → Audit Log with event-type filter, free-text search, and pagination.
* New: Health page under Magic Link → Health that checks wp_mail availability, table integrity, scanner-protection status, and token-lifespan sanity, with a single rollup status.
* New: Copy Magic Link button on the Magic Link → Magic Links list table. A new Actions column shows a visible Copy button for every row (active, used, and expired) that drops the link onto the clipboard.
* New: Black tooltip with a downward-pointing arrow appears above the Copy button when a link is copied, with a subtle row-vibrate animation in place of the previous blocking alert. Respects `prefers-reduced-motion`.
* New: CSV export of audit events **PRO**.
* New: Anomaly detector that flags failed-attempt bursts from one IP and sign-ins from never-seen countries per user **PRO**.
* Fix: Login after redirect issue.
* Fix: Empty `max_requests` or `time_window` values in PRO Login Request Throttling no longer reduce the limit to zero. Defensive defaults of 10 requests / 15 minutes are applied when the saved values are missing, empty, or non-positive, preventing the "Too many login link requests" error on first send.

= 1.4.1 =

* Fix: Fixed a bug where the Magic Link was not generated using the short code.

= 1.4.0 =

* New: Email-scanner protection. No longer silently consume single-use magic tokens. A short confirmation page requires an explicit click before login completes.
* New: Per-user "Revoke Magic Links" row action and bulk action on `users.php`.
* New: Inline resend cooldown on the `[magic_link_form]` shortcode (default 30s, filterable via `kc_ml_resend_cooldown`).
* New: Optional "Lost your password?" replacement filter that routes the WordPress recovery flow to the magic-link request page.
* Update: Verified compatibility with PHP 5.6 through PHP 8.2.
* Fix: Code improvements.

= 1.3.4 =

* New: UI Improvements.
* Update: WordPress 7.0 compatibility.

= 1.3.3 =

* Update: WordPress 7.0 compatibility.

= 1.3.2 =

* New: Added new "Trusted Domains" feature to allow users to receive Magic Link even if they don't have a user account on the site. **PRO**
* New: UI Improvements.
* Fix: Fatal error while generating Magic Link.
* Translations: Updated .POT file for new translations.

= 1.3.1 =

* New: UI Improvements.
* Translations: Updated .POT file for new translations.

= 1.3.0 =

* New: UI Improvements.
* Translations: Updated .POT file for new translations.

[See changelog for all versions](https://kaizencoders.com/docs/magic-link/changelog).