The limitations to using custom widgets are as follows:
The maximum size of an custom widget file cannot exceed 500 KB
The title you provide to an custom widget cannot exceed 256 characters
You can install maximum 50 extensions (including custom fields and custom widgets) in a stack
The size of the configuration file of a custom widget cannot exceed 10 KB
The maximum number of content types that can be added in the scope of a custom widget is 20
Internally as well externally hosted custom widgets are not supported on Internet Explorer and Microsoft Edge as these browsers lack support for the <iframe> srcdoc attribute. Read more.
Extensions are loaded in an iframe in sandbox mode for security reason. Hence, the cookies are not exposed. However, as popups are allowed in the current sandbox mode, you can open the popup window and access the cookies or storage in the popup window.