Note: You are currently viewing documentation for Moodle 3.4. Up-to-date documentation for the latest stable version of Moodle is likely available here: Switch roles.

Switch roles

From MoodleDocs

Switching temporarily to another role

The switch roles feature allows a user to switch temporarily to another role from the user menu 'Switch role' so that they can see what the course would look like to someone with that role.

SwitchRoleUserMenu.png

Switching roles is not perfect because you remain the same user, and your user may not have things like grades, which will make some student views look different than a real student might see. To get an 100% accurate view, the best thing to do is create a test student account and enrol it in your course. It is useful to have this logged-in on another browser so you can quickly switch back and forth.

Another way to see a student view is to "Log in as" one of your real students. You need the special capability user:loginas for this, and you do need to be careful that you don't accidentally change things for that student.

Site administration settings

The list of roles that you can switch to is set in the "Allow role switches" tab in 'Define roles' in the site administration.

See also