A Moodle enrollment plugin that enables course payments through Redsys payment gateway, the leading payment processor in Spain.
- Seamless integration with Redsys payment gateway
- Support for Euro (EUR) currency
- Automatic enrollment upon successful payment
- Email notifications for students, teachers, and admins
- Test mode for development and staging environments
- Configurable enrollment duration
- Role assignment on enrollment
- Secure SHA-256 signature verification
Redsys is the leading payment gateway service in Spain, processing payments for major Spanish banks and financial institutions.
- Moodle 3.5 or higher
- PHP 7.4 or higher
- Redsys merchant account with API credentials
cd /path/to/moodle/enrol
git clone https://github.com/harregoces/moodle-enrol-redsys.git redsys- Download the latest release
- Extract the contents
- Copy the
redsysfolder to/path/to/moodle/enrol/ - Visit Site Administration > Notifications to complete the installation
- Go to Site Administration > Plugins > Enrolments > Manage enrol plugins
- Enable "Redsys" enrollment
- Click on "Settings" to configure the plugin
- Enter your Redsys credentials:
- Merchant Code (FUC)
- Terminal Number
- Secret Key (SHA-256)
- Configure notification settings as needed
For testing in sandbox mode:
- Use the Redsys test environment credentials
- Enable test mode in the plugin settings
- Use test card numbers provided by Redsys
- Navigate to the course you want to enable payments for
- Go to Course Administration > Users > Enrolment methods
- Add "Redsys" from the dropdown
- Configure the enrollment cost
- Save changes
Students will see the payment option when they try to enroll in the course.
This plugin uses the official Redsys API PHP Library v1.0 with SHA-256 signature verification for secure transactions.
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
Hernan Arregoces - Software Engineer specialized in Moodle Development
This project is licensed under the GPL-3.0 License - see the LICENSE file for details.
If you find this plugin useful, consider giving it a star on GitHub!
Made with love for the Moodle community in Spain


