diff --git a/public/course/editsection_form.php b/public/course/editsection_form.php
index 5263b02cc53..dd4031f4807 100644
--- a/public/course/editsection_form.php
+++ b/public/course/editsection_form.php
@@ -39,7 +39,18 @@ class editsection_form extends moodleform {
$mform->setDefault('name', $sectioninfo->name);
$mform->addRule('name', get_string('maximumchars', '', 1333), 'maxlength', 1333, 'client');
- /// Prepare course and the editor
+ // Prepare course and the editor.
+
+ if ($sectioninfo->is_delegated()) {
+ // Show a warning that subsection descriptions will be discontinued.
+ $warning = $OUTPUT->notification(
+ message: get_string('subsectiondescriptionwarning', 'course'),
+ type: \core\output\notification::NOTIFY_WARNING,
+ closebutton: false,
+ titleicon: 'i/circleinfo',
+ );
+ $mform->addElement('static', 'subsectionwarning', '', $warning);
+ }
$mform->addElement('editor', 'summary_editor', get_string('description'), null, $this->_customdata['editoroptions']);
$mform->setType('summary_editor', PARAM_RAW);
diff --git a/public/lang/en/course.php b/public/lang/en/course.php
index a86319338b3..c6c32124742 100644
--- a/public/lang/en/course.php
+++ b/public/lang/en/course.php
@@ -153,6 +153,7 @@ $string['searchresults'] = 'Search results: {$a}';
$string['sectionlink'] = 'Permalink';
$string['showstartedcoursestask'] = 'Show courses on start date';
$string['submitsearch'] = 'Submit search';
+$string['subsectiondescriptionwarning'] = 'Subsection descriptions will be discontinued in Moodle 5.2. To add a description, use a Text and media area instead.';
$string['supports'] = 'This activity supports';
$string['studentsatriskincourse'] = 'Students at risk in {$a} course';
$string['studentsatriskinfomessage'] = 'Hi {$a->userfirstname},
diff --git a/public/mod/subsection/tests/behat/subsection_actionmenu.feature b/public/mod/subsection/tests/behat/subsection_actionmenu.feature
index 867301e77ae..ef0ac99062c 100644
--- a/public/mod/subsection/tests/behat/subsection_actionmenu.feature
+++ b/public/mod/subsection/tests/behat/subsection_actionmenu.feature
@@ -103,12 +103,17 @@ Feature: The module menu replaces the delegated section menu
And I click on "Edit" "button" in the "[data-region='header-actions-container']" "css_element"
And I choose "Edit settings" in the open action menu
And the field "Section name" matches value "Subsection1"
+ And I should see "Subsection descriptions will be discontinued in Moodle 5.2"
And I click on "Cancel" "button"
And I am on the "C1 > Section 1" "course > section" page
# Section page. Open Subsection1 module action menu.
And I open "Subsection1" actions menu
And I choose "Edit settings" in the open action menu
And the field "Section name" matches value "Subsection1"
+ # But subsection description warning is not shown in section edit form.
+ And I am on "Course 1" course homepage
+ And I edit the section "0"
+ And I should not see "Subsection descriptions will be discontinued in Moodle 5.2"
@javascript
Scenario: Permalink option in subsection action menu