Deprecation: #100033 - TBE_STYLES stylesheet and stylesheet2

See forge#100033


The usage of $GLOBALS['TBE_STYLES']['stylesheet'] and $GLOBALS['TBE_STYLES']['stylesheet2'] to add a custom CSS files to the TYPO3 backend has been marked as deprecated in TYPO3 v12 and will be removed in TYPO3 v13.


Using any of the following configuration declarations

  • $GLOBALS['TBE_STYLES']['stylesheet']

  • $GLOBALS['TBE_STYLES']['stylesheet2']

will trigger a PHP deprecation notice and will throw a fatal PHP error in TYPO3 v13.

Affected installations

The extension scanner will find extensions using

  • $GLOBALS['TBE_STYLES']['stylesheet']

  • $GLOBALS['TBE_STYLES']['stylesheet2']

as "weak" matches.


Extensions should use $GLOBALS['TYPO3_CONF_VARS']['BE']['stylesheets']['my_extension'] where 'my_extension' is the extension key.


$GLOBALS['TYPO3_CONF_VARS']['BE']['stylesheets']['my_extension'] = 'EXT:my_extension/Resources/Public/Css';

In the example above, all CSS files in the configured directory will be loaded in TYPO3 Backend.