SSO setup with Moodle using Drupal IdP

Last updated on
12 March 2026

This guide will help you in configuring SAML IDP 2.0 Single Sign-On (SSO), which allows you to integrate Moodle as a Service Provider and Drupal as an Identity Provider. By following these steps, you can enable SAML Single Sign On, which allows users to sign into Moodle LMS using their Drupal credentials.

The Drupal SAML SSO - Identity Provider module is compatible with Drupal 7, Drupal 8, Drupal 9, Drupal 10, and Drupal 11.

Download  Know more  Free Trial

Prerequisite:

  • Install and activate the SAML SSO - Identity Provider module on your Drupal site. Click here to check out the module installation step.
  • Download the plugin from the Moodle Plugin Directory and install it in the Moodle. Refer to the steps below:
    • Login as administrator in Moodle.
    • Navigate to the Site AdministratorPluginsInstall plugins. In Plugin installer → beside the ZIP package → click on Choose a file.
      • A File Picker window will appear, on the left side, select Upload a file and then click on the Choose File button (upload the zip file that you downloaded in the previous steps from the Moodle Plugins Directory) under Attachment.
      • Click on the Upload this File button.
    • Now, click the Install the plugin from the ZIP file button and then click on the Continue button to proceed.
    • In the next screen, click on the Upgrade Moodle database now button, and then click on Continue button.

Drupal SAML IdP Metadata:

  • After installing the module on your Drupal site, in the Administration menu → navigate to ConfigurationPeopleminiOrange SAML IDP Configuration. (/admin/config/people/miniorange_saml_idp/idp_setup)

    Drupal-SAML-IDP-SSO-Login-in-Configuration-Select-miniOrange-SAML-IDP

  • Under the IDP Metadata tab, click on the Download Metadata button (simply this file is open it on the notepad and copy the IdP information). Keep it handy. This information is required to configure Moodle as SAML SP.

    Drupal-SAML-IDP-click-on-download-metadata-button

Configure SAML SSO Application in Moodle LMS (E-learning):

  • Log in to your Moodle administrator account.
  • Navigate to the Site administratorPluginsPlugins overview  Additional plugins.
  • Click on the Settings link under Actions.

    Moodle-Single-Sign-On-Administration-Plugins-overview-click-on-Settings

  • Under the Service Provider Metadata tab and click on the DOWNLOAD link to download the XML metadata file. Keep the metadata file handy. This is required to configure Drupal as SAML Identity Provider (IdP).

    Moodle-SAML-Single-Sign-On-click-on-download-metadata

  • Go to the Service Provider Setup tab of the plugin and click on the Upload IdP Metadata button.

    Moodle-Single-Sing-on-Click-on-Upload-IdP-Metadata-btn

  • Enter the Identity Provider Name and paste the previously copied IdP metadata file from Drupal into the IdP Metadata XML text field. Then, click on the Upload Metadata button.

    Moodle-SAML-Single-Sign-on-paste-the-IdP-metadata-file-in-the-field

  • You have successfully saved the Drupal SAML IdP information into your Moodle site.

    Moodle-SAML-SSO-Saved-successfully-IdP-information

Configure Drupal as SAML Identity Provider:

  • Navigate to the Drupal site. Go to the Service Provider Setup tab of the module and click on the Upload SP Metadata.
  • In the Upload a metadata file field, choose the SP metadata file which you downloaded from the Moodle, and then click on the Fetch Metadata button.

    Drupal-SAML-IDP-upload-the-Moodle-SP-Metadata

You have successfully configured the Moodle as Service Provider and Drupal as SAML Identity Provider.

Test Connection between Moodle and Drupal:

  • Navigate to your Moodle site.
  • In the Moodle dashboard → Site administrationPluginsPlugins OverviewAdditional pluginsSettings.
  • Go to the plugin's Service Provider Setup tab. Scroll down and click on the Test Configuration button to check the connection between Moodle and Drupal.

    Moodle-SAML-Single-Sign-on-click-on-test-configuration-button

  • On a Test Configuration popup, if you don't have an active session on Drupal in the same browser, you will be asked to sign in to the Drupal site. After successfully logging into the Drupal site, you will be provided with a list of attributes that are received from the Drupal site.
  • Click on the Done button.

    Moodle-test-configuration-window-received-attribute-from-the-Drupal

If you face any issues in test configuration, you can reach out to us at drupalsupport@xecurify.com with a screenshot of the test configuration window.

Contact our 24*7 support team

Feel free to reach out to our Drupal experts if you need any sort of assistance in setting up SAML Single Sign-On (SSO) on your Drupal site.

Get In Touch With Us Join Our Slack Channel

back to top Back to top  

Help improve this page

Page status: No known problems

You can: