Why use it?

Restricting access to Moodle activities allows you to control the student’s learning journey through your course materials.

Step 1: Edit settings and choose restriction type

Turn editing on, click on the (blue star) icon next to the activity you wish to restrict, and select(blue star) Edit settings. Expand the Restrict access section.

Click the Add restriction… button.

Display of the restrict access subsection for the activity settings. There is a grey button that reads 'add restriction'.

You can now choose from a number of restriction types, as follows. Note that some of these restriction types (indicated by *) will only appear if other settings in the course allow it.

These restriction types are explained in the next section.

Step 2: Specify criteria

The sections below explain the criteria settings for each restriction type. Some settings are common to all restriction types, and these are covered in the first restriction type below.

Date (and common settings)

Once you choose Date, Moodle will add an access restriction to the form as follows:

Display of a date type restriction which requires the input of date details.

There are 3 settings:

If you want to set a date range, you will need to click Add restriction… again and add a second date.

Note that, once you have more than one restriction in place, the settings then look like this:

Display of a date type restriction for a date range which requires the input of date details.

There is now an additional setting:

Note that each restriction also has an 'eye' button (blue star) to the left of the date (common to all restriction types). Click this button to toggle between:

Finally, note also that any restriction can be removed by clicking the (blue star) button on its right (common to all restriction types).

When all your date restrictions are in place, click Save and display or Save and return to course at the bottom of the page.

Activity completion

Upon choosing this option, Moodle will add the restriction to the form as follows:

Display of an activity completion type restriction which requires the selection of appropriate activity displayed within a dropdown menu.

There are 2 settings:

Grade

Upon choosing this option, Moodle will add the restriction to the form as follows:

Display of a grade type restriction which requires the input of a grade range.

The settings are:

Students will only be able to access the current activity (the one we are editing) if they have achieved a grade within the specified range for the specified activity.

Group/Grouping

Upon choosing this option, Moodle will add the restriction to the form as follows:

Display of a group type restriction which requires the selection of a group from a dropdown menu.

The only setting required is to specify the Group or Grouping that is allowed to view this activity.

Important: If you want to give each of the groups in a course separate access to an activity (such as a forum or assignment), this is not the way to do it. You can save yourself a lot of effort by using Group Mode instead. See How to use Groups and Groupings to manage group activities for details.

User profile

This restriction uses information in the student’s user profile to control access. This can be used to restrict access to specified individuals, by matching against their email address (which is unique to each individual).

Moodle will add the restriction to the form as follows:

Display of a user profile type restriction which requires the selection of a user profile field from a dropdown menu.

The settings are:

Only users whose profile fields match the specified comparison will be able to access the activity. This is useful when providing resources to individual students with specific requirements.

IMPORTANT: Always close the eye-icon (blue star) , to hide the criteria when specifying individual students, so that their identities are not visible to other students. This is especially important when restricting access to students with Inclusion Plans (IPs).

Restriction set

This is not really a restriction type, but simply a framework for adding hierarchy to your restrictions.

For example, suppose you wanted to restrict access to an activity such that it was available to all students within a given date range, but also available to members of a specific group outside of that date range.

First, you would add the group restriction as follows:

Displays the group type restriction with Group 1 selected from a dropdown menu.

Next, click Add restriction… again and choose Restriction set. The form now looks like this:

Display of a restriction set which has a group type restriction and the option to input a second restriction type.

You have created a subsection into which the date range can be set up. Add the start and end dates:

Display a restriction set which includes a group type restriction and date type restriction with a date range.

Finally, you would need to change the first “all” into “any”, so that students get access if they are members of Group A or the current date is within range.