Microsoft Block

Blocks ::: block_microsoft
Maintained by Enovation Dev Team, James McQuillan, Nima Mojgani, Zion Brewer
This block provides a user-facing menu to access various Microsoft 365 integration features, resources, and settings.
Latest release:
3152 sites
55 fans
Current versions available: 6

Microsoft 365 Plugins for Moodle

Microsoft Block

This block provides a user-facing menu to access various Microsoft 365 integration features, resources, and settings.

NOTE: This plugin replaces the two profile field plugins in the Microsoft 365 plugin set: profilefield_oidc and profilefield_o365.

This is part of the suite of Microsoft 365 plugins for Moodle.

To follow active development on GitHub, or to find historical versions, click here.

This plugin is updated with stable Moodle releasesThis means as of October 2022:

  • The versions for Moodle 3.11 and 4.0 gets full support. Any new features are guaranteed to be added to these two versions.
  • The version for Moodle 3.9 gets security support. New features are not to be added to this version, but some bug fixes may be added.
  • All other versions, included the one for Moodle 3.10, are out of support.

Questions and issue reporting

Github should be used for reporting issues found when configuring or using the plugin, and to ask questions. The comments area on this page is not actively monitored.


Before we can accept your pull request, you'll need to electronically complete Microsoft's Contributor License Agreement. If you've done this for other Microsoft projects, then you're already covered.

Why a CLA? (from the FSF)


(c) Microsoft, Inc.

Code for this plugin is licensed under the GPLv3 license.

Any Microsoft trademarks and logos included in these plugins are property of Microsoft and should not be reused, redistributed, modified, repurposed, or otherwise altered or used outside of this plugin.


This plugin is part of set Microsoft 365.


Screenshot #0
Screenshot #1


Enovation Dev Team (Lead maintainer)
Akinsaya Delamarre
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Thu, Aug 11, 2016, 5:11 PM
    James - I later came across Thomas College's post regarding granting permissions for Authenicated Users "Allowing OpenID Connection and Disconnection". This was spot on and corrected my issue. Thanks to all for the help.
  • Mon, Sep 5, 2016, 9:31 PM

    Not sure if this is at all related but it seems as though it might be. We are unable to run our daily cron. The error I have listed is as follows:

    Server Time: Mon, 05 Sep 2016 13:30:46 +0000

    Execute scheduled task: Sync with SDS (local_o365\feature\sds\task\sync)
    ... started 13:30:46. Current memory use 14.7MB.
    !!! Coding error detected, it must be fixed by a programmer: A lock was created but not released at:
    [dirroot]\lib\classes\task\manager.php on line 475

    Code should look like:

    $factory = \core\lock\lock_config::get_lock_factory('type');
    $lock = $factory->get_lock(Resource id #607);
    $lock->release(); // Locks must ALWAYS be released like this.


    Any Ideas?
  • Wed, Oct 5, 2016, 12:30 PM
    Hi Paul, I'm not sure why you're seeing that message - will investigate further. In the meantime, you can disable the task by going to the scheduled tasks settings page ([moodle URL]//admin/tool/task/scheduledtasks.php), clicking the gear icon next to the "Sync with SDS" and checking "Disable". Unless you are using school data sync, this task does not do anything anyway so it is safe to disable. Thanks!
  • Thu, Dec 1, 2016, 3:44 PM
    Hi, somebody facing the same problem with the calender? It´s just syncing one way moodle -> outlook, even if I check both ways, moodle version 2.8.12, thanks tom
  • Thu, Dec 1, 2016, 5:32 PM
    Sorry, cronjob was not runnning ;)
  • Thu, Dec 1, 2016, 7:47 PM
    Anyway looks like it´s not perfectly working, if I change or delete a calendar entry in Outlook, I can´t see the changes in Moodle sad
  • Tue, Jan 31, 2017, 10:26 PM
    This block has been very helpful for two Moodle sites that I manage! Is there a way to find out how many users have linked their accounts via the Microsoft block? We authenticate via LDAP, not Office 365 Azure, so users have to link manually.
  • Fri, Feb 3, 2017, 6:21 AM
    @bryce - If you can execute manual SQL queries on your database, the "mdl_auth_oidc_token" database will help you get that information. We don't currently have a front-end for that statistic though.
  • Wed, Apr 5, 2017, 11:48 PM
    Hello, we love this plugin but we have a problem

    We are going to upgrade to Moodle 3.1 and reviewing the Groups we found that we can't see Study Groups in the Microsoft Block.

    In /blocks/microsoft/block_microsoft.php on line 143 is the following code in comments:

    // If (! Empty ($ config ['settings_showstudygroups'])) {
                        // Temporarily removed pending further design work.
    //                    $ Studygroups = \ local_o365 \ feature \ usergroups \ utils :: study_groups_list ($ USER-> id, ['courseid' => $ PAGE-> context-> instanceid], false, 0, 5);
    //                    $ Items = array_merge ($ items, $ studygroups);
    //                }

    We remove the comments and we already see the list of Study Groups.

    There are also two lost folders that are in Moodle 2.7
    / Moodle / blocks / microsoft / groups /
    / Moodle / blocks / microsoft / tests /

    Our students and teachers are already using Study Groups and we can not remove this option.

    We need help to know what files and folders to add so we not lose the functionality that was already in Moodle 2.7
  • Wed, May 3, 2017, 9:17 PM
    Hello, in my microsoft blocks the link to the OneNote is not showing up. Would anyone know what can be done to solve this problem? see the print
  • Tue, Jun 26, 2018, 8:03 PM
    Hi I was just wondering about the progress on the School Data Sync option. Does it work? Can it create Moodle Courses and synchronise the enrolment of Students based on their membership to Office 365 Class Groups on Azure?
  • Mon, Oct 22, 2018, 5:13 PM
    Good Morning
    We are using the microsoft block in our school.
    I would like to suggest an improvement to the block.
    It would be highly recommended that in the access to My email, the number of unread messages or at least one asterisk appear in parentheses indicating that there is an unread message.
    Thanks greetings
  • Tue, May 21, 2019, 12:39 AM
    I have a problem I miss this message:

    'You are almost connected to Office 365
    You have been assigned the Office 365 user ""

    To complete the connection, click on the following link and log in to this Office 365 account.

    Log in to Office 365'

    But he does not log me in.

    Can someone help me?
  • Fri, Nov 20, 2020, 4:53 PM
    Hello Carlos,
    I had the same problem connecting the plugin to my personal resource . Most likely you need to see if the authorization in Microsoft Office is correct. If not, you will need to create a new account and turn on the plugin again using this data.
  • Fri, Nov 12, 2021, 10:30 PM
    Hello Author,

    I have installed this plugin in my moodle site. then I go to setting and click on "Provide Admin Consent" button
    then i am getting this screen and errors - "AADSTS90027: We are unable to issue tokens from this API version on the MSA tenant. Please contact the application vendor as they need to use version 2.0 of the protocol to support this."
    Please help me to fix this issue. I want to sync my moodle calendars to outlook calendars via this plugins. thanks
1 2
Please login to post comments