@BeaUserWay in earlier on-premise versions of SharePoint there was the script editor. That is not available in SharePoint Online out-of-the-box it's on a modern page not possible to add scripts. On a classic page it's still possible to use the script editor but the settings have to be switch on by your tenant admin (though most IT departments won't allow it in my experience). Info on this is here.
Rob Los Gallardos Intranet, SharePoint and Power Platform Manager (and classic 1967 Morris Traveller driver)