Custom login form for WordPress
How to create custom login form for your WordPress site where (optionally) only specific user roles are allowed to login.
Creating a custom WordPress login form
First edit your form and navigate to Form Settings > Register & Login. From the Actions option choose Login (user will be logged in). Now when the form is being submitted it will try to login the user.

Allowing only specific user roles to login to your WordPress site
Now select the roles that should be allowed to login, or leave black to allow all roles.

Defining the login page URL

Verification of E-mail address
If your registration form is configured to send a verification E-mail after registering a new account, you will want to make sure you add the Verification Code element to your Login form.

Whenever the user clicks the verification link inside the E-mail, they will be redirected to the defined login page where they can enter the verification code to activate their account. As shown below.

Last updated