Getting Started with CognitoPress

Learn how to set up CognitoPress from scratch — explore the admin settings, add authentication blocks with Gutenberg, and build sign-in and profile pages in minutes.

🔧 Set Up CognitoPress and Add the Login Flow to Your Site

This tutorial walks you through using the CognitoPress admin panel, adding authentication blocks in the Gutenberg editor, and configuring a login page.

Step 1: Install the CognitoPress Plugin

You can install CognitoPress in two ways:

  1. Manual Installation
    Download the plugin ZIP file here:
    Download cognitopress.zip
    Then in your WordPress dashboard:
    Go to Plugins → Add New → Upload Plugin, select the ZIP file, and click Install Now, then Activate.
  2. From WordPress Plugin Directory (Coming Soon)
    Once available on wordpress.org/plugins/cognitopress/, you’ll be able to install it by searching “CognitoPress” under Plugins → Add New and clicking Install Now.

Step 2: Open the CognitoPress Admin Panel

Go to WP Admin → CognitoPress → Settings. This is where you’ll connect your Cognito User Pool and control plugin behavior.

📷 Screenshot placeholder: Admin panel open

Step 3: Create a Pattern with the Authenticator Block

  1. Create a new page in the Gutenberg editor.
  2. Add the Authenticator block.
  3. Set its properties: initial screen, layout, color mode, etc.
  4. Save the page as a Reusable Pattern.
📷 Screenshot placeholder: Gutenberg block settings

Step 4: Use a Shortcode or Insert the Pattern

You can now use the login flow in two ways:

  • Insert the pattern directly on your sign-in page.
  • Use a shortcode like:
cognitopress id="your-pattern-id"
📷 Screenshot placeholder: Example page with shortcode

Step 5: Set Your Login Page in CognitoPress

Back in CognitoPress → Settings → General, choose the WordPress page you created as the “Sign In Page”.

This ensures unauthenticated users are redirected to the correct login flow.

📷 Screenshot placeholder: General settings – sign in page

Step 6: Enable WordPress Login Integration

To fully replace the native WordPress login screen (/wp-login.php), go to CognitoPress → Settings → WordPress Login.

  • Enable the “Integrate WordPress Login” option.
  • This allows users who log in with Cognito to also gain access to the WordPress backend (if their role allows).
  • The plugin will automatically redirect the default login flow to the Cognito-based screen you’ve configured.

Once activated, your Cognito-based login replaces /wp-login.php — including admin access and login-required redirects.

📷 Screenshot placeholder: Enable “Integrate WordPress Login” checkbox

Step 7: Map Cognito Groups to WordPress Roles

When WordPress Login Integration is enabled, you can assign WordPress roles to users based on their Cognito groups.

Go to CognitoPress → Settings → WordPress Login and scroll to the “Cognito Group to WordPress Role Mapping” section.

  • Enter the exact name of each Cognito group (case-sensitive).
  • Select the corresponding WordPress role from the dropdown list.
  • Users will automatically receive the mapped role upon login.

If a user doesn’t match any mapped group, they may receive the default role or no access to WP backend — depending on your configuration.

📷 Screenshot placeholder: Group-to-role mapping table

🔄 Plugin Behavior and Fallbacks

When the plugin is active and a new user registers through Cognito, CognitoPress:

  • Creates the user in the Cognito User Pool
  • Also inserts the user into the WordPress database with the correct role (if WordPress is available)

This ensures WordPress-based features like dashboards or custom plugins still function.

Note: In headless setups (where WordPress is not running at registration time), local user sync will not occur — only Cognito will have the user record.

CognitoPress does not store passwords in WordPress. However, users can always reset their password later via Cognito if needed (or WordPress if CognitoPress is deactivated).

✅ You’re Done!

You now have a working Cognito login flow inside your WordPress site — visually integrated, and fully managed via CognitoPress.