Your Moodle version

Enrolment: AutoEnrol

Maintained by Picture of Mark Ward Mark Ward
Adds functionality to automatically enrol users onto a course, either as they log into your Moodle site or as they acess a course. This plugin is primarily intended for use on courses which you want all users to be able to access but can also be configured for more advanced purposes.
Moodle 2.0, 2.1, 2.2, 2.3, 2.4, 2.5

When added to a course this enrolment plugin can enrol users onto a course automatically, either as they log into your Moodle site or as they click on the course. It is intended for use on site-wide courses such as "Moodle Help" or "Learner Voice".

In addition the plugin has advanced functionality to support autmatically grouping and filtering users based upon their attributes. Depending on how your user accounts are set
up this may help you to give access to certain user groups.

Configuration of the plugin is managed by two permissions which allow administrators to easily control who has access to the plugin.


Screenshot #0
Screenshot #1


Picture of Mark Ward
Mark Ward (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
  • Picture of Bryce Holland
    Tue, Dec 23, 2014, 6:00 AM
    Mark, I don't understand. I add a word to the "Department" section of the test student account. I then setup the AutoEnrol plugin to add any account with that word in the "Department" field. The autoenrol works. However, I edit the test student account and remove that word from the "Department" field. I log back in and the account is still enrolled in the course. I need it so the account is removed from the course if that word is not in that field. Does it not work that way?
  • Picture of Mark Ward
    Tue, Dec 23, 2014, 8:06 PM
    Hi Bryce,

    You are correct, it doesn't unenrol users when their information no longer matches the filter. I can appreciate why you would want it to work like that but simply put the plugin wasn't designed around a protected course but rather a more public course which you want to get users enrolled onto as easily as possible.

    I've started a discussion (see link below) which outlines my thoughts on taking this forward. I'd love to hear your thoughts on what I am proposing.


  • Picture of Bryce Holland
    Tue, Dec 23, 2014, 8:54 PM
    Thank you, Mark. That makes sense. Thank you for creating a discussion forum about it. I will definitely participate and subscribe to it.
  • Picture of shruthi papu
    Mon, Dec 29, 2014, 7:08 PM
    how to add cohorts in moodle
  • Picture of John Akinbami
    Mon, Feb 2, 2015, 1:50 AM
    I could not use other custom profile field. Is there a way I can include it. E.g Class other than the pre define ones
  • Picture of Jürg Hoerner
    Thu, Feb 19, 2015, 4:29 AM
    I can not update. Error with a postgres DB an moodle 2.7
    . enrol_autoenrol
    Fehler beim Lesen der Datenbank

    Weitere Informationen über diesen Fehler

    Debug info: ERROR: invalid input syntax for integer: ""
    SELECT * FROM mdl_groups WHERE id = $1
    [array (
    0 => '',
    Error code: dmlreadexception
    Stack trace:
    line 443 of /lib/dml/moodle_database.php: dml_read_exception thrown
    line 244 of /lib/dml/pgsql_native_moodle_database.php: call to moodle_database->query_end()
    line 764 of /lib/dml/pgsql_native_moodle_database.php: call to pgsql_native_moodle_database->query_end()
    line 1305 of /lib/dml/moodle_database.php: call to pgsql_native_moodle_database->get_records_sql()
    line 1278 of /lib/dml/moodle_database.php: call to moodle_database->get_records_select()
    line 48 of /enrol/autoenrol/db/upgrade.php: call to moodle_database->get_records_list()
    line 535 of /lib/upgradelib.php: call to xmldb_enrol_autoenrol_upgrade()
    line 1615 of /lib/upgradelib.php: call to upgrade_plugins()
    line 434 of /admin/index.php: call to upgrade_noncore()
  • Picture of Mark Ward
    Thu, Feb 19, 2015, 6:17 PM
    Hi Jürg

    I've seen your ticket on GitHub and will take a look. Thanks for reporting it.

  • Picture of Samuel Than
    Fri, Feb 20, 2015, 1:37 PM
    Thanks for the awesome plugin...

    There's somethign strange with this plugin, i've installed that on Moodle 2.7.3 and configure it to auto enrol on a specific course. the users's that click on the course auto-enrolled without problem.. HOWEVER, there was no student role or any role assigned...

    Anything i've misconfigured ?

    Thanks for the help
  • Picture of Mark Ward
    Fri, Feb 20, 2015, 7:50 PM
    Hi Samuel,

    I've set up a ticket for you on the issue tracker for this plugin:

    So far I havent been able to reproduce the problem so I am going to need some more information from you. If you could sign up for a GitHub account and answer a couple of questions that would be great.


  • Head
    Wed, Jun 10, 2015, 6:56 PM
    Is a 2.9 version in the pipeline?

  • Picture of Dave Catlin
    Tue, Jun 16, 2015, 9:01 PM
    J have just downloaded a version for Moodle 2.5. I got a folder but nothing installed. Can you help?
  • Picture of Manuel Costales
    Sat, Jun 27, 2015, 4:46 AM
    Hi, I'm trying to install this plugin in the 2.5 version of moodle, but I'm getting an erro that says missing language folder, or something like that.
    How can I fix that?
  • Picture of John McDonald
    Fri, Jul 31, 2015, 9:20 PM
    This enrollment method definitely has potential. Have you considered enrollment by cohort only? Not to be confused with cohort sync, but that a user must be in a specified cohort before the autoenrol enrollment is "active".
  • Picture of Birva Mandalia
    Mon, Oct 26, 2015, 1:09 PM
    Does moodle have a plugin that imports all records from an Excel sheet and automatically Enrolls them for a particular Course creating their user ID and Password along with sending the users acknowledgement for the same. Creating a backup of the user IDs and password for the admin.
    Is there any plugin with this feature?
  • Picture of Sameer Kshirsagar
    Thu, Nov 26, 2015, 9:04 PM

    I am currently using moodle 2.7 version. I am able to install the Auto Enroll plugin and ist working fine. I would also like to set the enrollment duration for the courses. I did not see the enrollment duration option in the same. Is there any way to add the enrollment duration also?
1 2 3 4 5
Please login to post comments