Recently when i was working on one of the project requirements to hide quick launch items for a specific page (SharePoint Online) using script editor webpart(Embed Code webpart) on to the page, i got the below error while injecting the script
"This HTML cannot be inserted because you don't have access to add scriptable Web Parts in this site. Please contact your administrator if you think you should have rights to do so."
Go to admin portal --> SharePoint àSettings (url http://urdomainname-admin.sharepoint.com/_layouts/15/online/TenantSettings.aspx /_layouts/15/online/TenantSettings.aspx)
In Custom Script Section select the option "Allow users to run Custom script on personal sites and selfservice created sites.."
Note : As mentioned in the screen, to apply these changes it may take 24 hrs.