Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Social Auth Facebook

Security covered Maintenance fixes only 2,890 sites

Part of the Social ecosystem · 70 projects

This module allows users to register and log in to your Drupal site using their Facebook accounts. It handles the authentication process with Facebook and either logs in existing users or creates new accounts.

This project is part of the Drupal Social Initiative and is based on the Social API.

Social Auth Facebook allows users to register and login to your Drupal site with their Facebook account. The module allows websites to request any scopes, so any tasks requiring authentication with Facebook services can be performed. This module is based on Social Auth and Social API projects

This module adds a path user/login/facebook which redirects the user to Facebook for authentication.

After Facebook has returned the user to your site, the module compares the user id or email address provided by Facebook. If the user has previously registered using Facebook or your site already has an account with the same email address, the user is logged in. If not, a new user account is created. Also, a Facebook account can be associated with an authenticated user.

Login process can be initiated from the "Facebook" button in the Social Auth block. Alternatively, site builders can place (and theme) a link to user/login/facebook wherever on the site.

Configuration

In Drupal

  1. Log in as an admin.

  2. Navigate to Configuration » User authentication » Facebook and copy the Authorized redirect URL field value (the URL should end in /user/login/facebook/callback).

In Meta for Developers:

  1. Log in to a Facebook account.

  2. Navigate to My Apps.

  3. Click Create app.

  4. Enter a Display name for the app and click Create app.

  5. From the app landing page under Add products to your app > Facebook Login click Set up.

  6. Under Products > Facebook Login click Settings (do not use "Quickstart").

  7. Paste the URL copied from Step 2 in the Valid OAuth Redirect URIs field.

  8. Navigate to Settings > Basic.

  9. Copy and save the App ID value somewhere safe.

  10. Click Show for the App secret field. Copy and App secret value and save it somewhere safe.

  11. Navigate to Settings > Advanced.

  12. Under Upgrade API version note the API version in use (e.g., "14.0").

In Drupal:

  1. Return to Configuration » User authentication » Facebook

  2. Enter the Facebook app ID in the App ID field.

  3. Enter the Facebook app secret in the App secret field.

  4. Enter the API version in the Facebook Graph API version field.

  5. Click Save configuration.

  6. Navigate to Structure » Block Layout and place a Social Auth login block somewhere on the site (if not already placed).

That's it! Test the connection by logging in with your own account. For further testing navigate to Roles > Test Users to create and add other testers.

When ready log in to Meta for Developers, navigate to OAuth app, and change the App Mode to "Live" to allow any user with a Facebook account to log in.

Drupal 9–11 PHP >=8.1

Ask your assistant about Social Auth Facebook

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
5
Tracked since
May 2023
Latest release
2 years ago
Releases (12 mo)
0
Maintenance
Dormant

Release Timeline

Releases

Version Type Core PHP Release date
4.0.4 Stable 9–11 PHP >=8.1 Sep 7, 2024
4.0.3 Stable 9–10 Jul 27, 2023
4.0.2 Stable 9–10 Jun 21, 2023
4.0.1 Stable 9–10 Jun 5, 2023
4.0.0 Stable 9–10 May 3, 2023