TYPO3 v10 has reached end-of-life as of April 30th 2023 and is no longer being maintained. Use the version switcher on the top left of this page to select documentation for a supported version of TYPO3.

Need more time before upgrading? You can purchase Extended Long Term Support (ELTS) for TYPO3 v10 here: TYPO3 ELTS.

Add TypoScript in your extension


This part is written for extension developers.

Create TypoScript files in your extension

TypoScript files should have the ending .typoscript.

They are located in Configuration/TypoScript within your extension.

Usually, you will have the following structure:

└── TypoScript
    ├── constants.typoscript
    └── setup.typoscript
  • constants.typoscript contains the constants

  • setup.typoscript contains the TypoScript setup

Make TypoScript available for static includes


defined('TYPO3_MODE') || die();

   $extensionKey = 'myextension';

    * Default TypoScript
      'Some descriptive title'

If you include the TypoScript this way, it will not be automatically loaded. You MUST load it by adding the static include in the Web > Template module in the backend, see Include TypoScript from extensions. This has the advantage of better configurability.

This will load your constants and your setup once the template is included statically.


You may also want to make several different templates available.

Make TypoScript available (always load)

Only do this, if your TypoScript must really be always loaded in your site. If this is not the case, use the method described in the previous section Make TypoScript available for static includes.


defined('TYPO3_MODE') || die();

   $extensionKey = 'myextension';

      "@import 'EXT:myextension/Configuration/TypoScript/setup.typoscript'"

More information