- Admin quick guide
- Authentication
- Managing accounts
- Enrolments
- Payment gateways
- Roles and permissions
- Security
- Performance
- Backup
- Site registration
- Site appearance
- Language
- Server settings
- Site-wide reports
- Admin tools
- Developer tools
- Web services
- More features
- GDPR
- Communication
- MoodleNet
- SMS gateways
- Administration FAQ
The SMS gateways plugin allows different providers (e.g. AWS SNS) to send messages via SMS. Site administrators can set up and configure multiple SMS gateways. Only sending (not receiving) of messages is currently supported.
New feature
in Moodle 5.0!
The SMS subsystem is for use in Multi-factor authentication (MFA) and SMS notifications (new in 5.0 and only for assignment notifications initially). Note that SMS is not a replacement for notifications sent to the Moodle App; it is a supplementary mechanism. Many places in the world do not have access to internet-enabled phones, or have data restrictions, so SMS functionality provides an alternative way to receive important information.
Creating an SMS gateway
To create an SMS gateway:
- Go to Site administration > Plugins > SMS > Manage SMS gateways.
- Click "Create new SMS gateway".
- Enter the required information (see below) and save changes.
- SMS gateway provider - Currently AWS and Modica (new in 5.0) are available in standard Moodle.
- Gateway name - The name will be used identify the gateway in the list of configured gateways.
- 'Default country code: - The country code used if users have not included a country code when entering their mobile number. This is particularly useful if your users are (mostly) from one one region, as they won't need to add the country code while entering their mobile number in plugins such as MFA.
- The remaining fields are specific to the gateway plugin and require you to have an account.

In Site administration > Plugins > SMS > Manage SMS gateways, gateways can be enabled or disabled as required.

If the gateway is in use (e.g. MFA is using this gateway), then it will not be disabled and instead it will show a notification that it can not be disabled.

Gateways can also be deleted. A confirmation dialogue will be shown before deleting the gateway, as well as a notification after a successful deletion.


If the gateway is in use or any other issues are found while deleting the gateway, it will not be deleted and a notification will be shows with relevant information.

Once a gateway has been configured and enabled, you can select the gateway from the MFA SMS factor settings.

Admin locked out of site - how to resolve
Be careful as an administrator when configuring and testing the factors that you do not lock yourself out of the site. If you do then MFA can be disable from the command line by entering:
: php admin/cli/cfg.php --component=tool_mfa --name=enabled --set=0