TYPO3 ist ein leistungsstarkes Enterprise-CMS für komplexe Websites. Es bietet umfangreiche Funktionen für mehrsprachige Websites, Multisite-Setups und granulare Berechtigungen.
Warum TYPO3?
Vorteile
- Enterprise-Features
- Multisite und Multilingual
- Granulare Berechtigungen
- Starke Community
- Langfristige Updates
- DSGVO-konformTYPO3 vs. Andere CMS
| Feature | TYPO3 | WordPress | Drupal | |---------|-------|-----------|--------| | Komplexität | Hoch | Niedrig | Mittel | | Enterprise | Ja | Bedingt | Ja | | Multisite | Exzellent | Gut | Gut | | Lernkurve | Steil | Flach | Mittel | | Flexibilität | Sehr hoch | Mittel | Hoch |
Voraussetzungen
Systemanforderungen
- PHP 8.1+ (8.2 empfohlen)
- MySQL 8.0+ / MariaDB 10.3+ / PostgreSQL
- Apache oder Nginx
- Composer
- 256 MB RAM (512 MB empfohlen)
- 200 MB Festplatte + ContentPHP-Erweiterungen
- curl, fileinfo, gd, json, mbstring
- mysqli, openssl, pcre, session
- xml, zip, zlib, intl
- opcache (empfohlen)Server vorbereiten
LAMP-Stack installieren
apt update
apt install apache2 mariadb-server php php-mysql \
php-gd php-xml php-mbstring php-curl php-zip \
php-intl php-opcache php-apcu libapache2-mod-php
# Apache-Module
a2enmod rewrite headers expiresPHP konfigurieren
# /etc/php/8.2/apache2/php.ini
max_execution_time = 240
max_input_vars = 1500
memory_limit = 256M
upload_max_filesize = 50M
post_max_size = 50MComposer installieren
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composerDatenbank erstellen
mysql -u root -pCREATE DATABASE typo3 CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'typo3'@'localhost' IDENTIFIED BY 'SicheresPasswort!';
GRANT ALL PRIVILEGES ON typo3.* TO 'typo3'@'localhost';
FLUSH PRIVILEGES;
EXIT;TYPO3 installieren
Mit Composer
cd /var/www
composer create-project typo3/cms-base-distribution typo3 "^12"
cd typo3Verzeichnisstruktur
/var/www/typo3/
├── public/ # Document Root
│ ├── fileadmin/ # Benutzer-Uploads
│ ├── typo3/ # Backend
│ ├── typo3conf/ # Konfiguration
│ └── index.php # Frontend
├── var/ # Cache, Logs
├── vendor/ # Abhängigkeiten
└── composer.jsonBerechtigungen
chown -R www-data:www-data /var/www/typo3
chmod -R 755 /var/www/typo3Apache konfigurieren
Virtual Host
# /etc/apache2/sites-available/typo3.conf
<VirtualHost *:80>
ServerName example.com
ServerAlias www.example.com
DocumentRoot /var/www/typo3/public
<Directory /var/www/typo3/public>
Options FollowSymLinks
AllowOverride All
Require all granted
</Directory>
# Sicherheit
<DirectoryMatch "/var/www/typo3/(var|vendor)">
Require all denied
</DirectoryMatch>
ErrorLog ${APACHE_LOG_DIR}/typo3_error.log
CustomLog ${APACHE_LOG_DIR}/typo3_access.log combined
</VirtualHost>a2ensite typo3.conf
a2dissite 000-default.conf
systemctl reload apache2Nginx (Alternative)
# /etc/nginx/sites-available/typo3
server {
listen 80;
server_name example.com www.example.com;
root /var/www/typo3/public;
index index.php index.html;
# Security
location ~ /\. {
deny all;
}
location ~ ^/(vendor|var)/ {
deny all;
}
# Static files
location ~* \.(jpg|jpeg|gif|png|css|js|ico|svg|woff2?)$ {
expires 30d;
access_log off;
}
# TYPO3 Frontend
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
# PHP
location ~ \.php$ {
include fastcgi_params;
fastcgi_pass unix:/var/run/php/php8.2-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_buffer_size 128k;
fastcgi_buffers 256 16k;
}
}Web-Installation
Install Tool starten
URL: http://example.com/typo3/install.php
Installationsschritte
1. System-Check (PHP, Extensions)
2. Datenbank-Verbindung:
- Host: localhost
- Benutzer: typo3
- Passwort: SicheresPasswort!
- Datenbank: typo3
3. Admin-Benutzer erstellen
4. Site-Name eingeben
5. Fertig!Nach der Installation
# FIRST_INSTALL entfernen
rm /var/www/typo3/public/FIRST_INSTALLCLI-Installation
cd /var/www/typo3
# Datenbank konfigurieren
./vendor/bin/typo3 setup \
--dbhost=localhost \
--dbname=typo3 \
--dbuser=typo3 \
--dbpassword='SicheresPasswort!' \
--admin-username=admin \
--admin-password='AdminPasswort!' \
--admin-email=admin@example.com \
--site-name="Meine Website"Backend-Zugang
Login
URL: http://example.com/typo3
Benutzer: admin
Passwort: (bei Installation gesetzt)Wichtige Module
Web → Page: Seitenbaum und Inhalte
Web → List: Datensatz-Ansicht
File → Filelist: Datei-Manager
Admin → Users: Benutzer-Verwaltung
System → Install: Wartung und UpdatesKonfiguration
LocalConfiguration.php
// /var/www/typo3/config/system/settings.php
// Oder: /var/www/typo3/public/typo3conf/LocalConfiguration.php
return [
'BE' => [
'installToolPassword' => '...',
'passwordHashing' => [
'className' => 'TYPO3\\CMS\\Core\\Crypto\\PasswordHashing\\Argon2iPasswordHashing',
],
],
'DB' => [
'Connections' => [
'Default' => [
'charset' => 'utf8mb4',
'dbname' => 'typo3',
'driver' => 'mysqli',
'host' => 'localhost',
'password' => 'SicheresPasswort!',
'port' => 3306,
'user' => 'typo3',
],
],
],
'FE' => [
'cacheHash' => [
'enforceValidation' => true,
],
],
'SYS' => [
'sitename' => 'Meine Website',
'encryptionKey' => 'langerZufälligerSchlüssel...',
'trustedHostsPattern' => 'example\\.com|www\\.example\\.com',
],
];AdditionalConfiguration.php
// /var/www/typo3/public/typo3conf/AdditionalConfiguration.php
// Debug-Modus (nur Entwicklung!)
$GLOBALS['TYPO3_CONF_VARS']['BE']['debug'] = true;
$GLOBALS['TYPO3_CONF_VARS']['FE']['debug'] = true;
// Caching deaktivieren (nur Entwicklung!)
foreach ($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'] as $table => $conf) {
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations'][$table]['backend'] = \TYPO3\CMS\Core\Cache\Backend\NullBackend::class;
}Extensions
Extension installieren
# Mit Composer
composer require vendor/extension-name
# z.B. News-Extension
composer require georgringer/newsExtension aktivieren
Admin Tools → Extensions → InstallierenWichtige Extensions
# News-System
georgringer/news
# SEO
yoast/yoast-seo-for-typo3
# Formulare (Core)
typo3/cms-form
# Indexed Search (Core)
typo3/cms-indexed-search
# Scheduler (Core)
typo3/cms-schedulerSite Configuration
config.yaml
# /var/www/typo3/config/sites/main/config.yaml
rootPageId: 1
base: 'https://example.com/'
languages:
-
title: Deutsch
enabled: true
languageId: 0
base: /
typo3Language: de
locale: de_DE.UTF-8
iso-639-1: de
navigationTitle: Deutsch
flag: de
-
title: English
enabled: true
languageId: 1
base: /en/
typo3Language: en
locale: en_US.UTF-8
iso-639-1: en
navigationTitle: English
flag: gb
fallbackType: fallback
fallbacks: '0'
errorHandling:
-
errorCode: '404'
errorHandler: Page
errorContentSource: 't3://page?uid=10'
-
errorCode: '500'
errorHandler: Fluid
errorFluidTemplate: 'EXT:my_extension/Resources/Private/Templates/Error.html'
routes: []TypoScript-Grundlagen
Setup
# Root-Template: Setup
page = PAGE
page {
typeNum = 0
10 = FLUIDTEMPLATE
10 {
templateName = Default
templateRootPaths.0 = EXT:my_sitepackage/Resources/Private/Templates/
partialRootPaths.0 = EXT:my_sitepackage/Resources/Private/Partials/
layoutRootPaths.0 = EXT:my_sitepackage/Resources/Private/Layouts/
variables {
content < styles.content.get
content.select.where = colPos = 0
}
}
# CSS einbinden
includeCSS {
main = EXT:my_sitepackage/Resources/Public/Css/main.css
}
# JavaScript
includeJSFooter {
main = EXT:my_sitepackage/Resources/Public/JavaScript/main.js
}
}Constants
# Root-Template: Constants
site {
name = Meine Website
email = info@example.com
}Caching
Cache leeren
# CLI
./vendor/bin/typo3 cache:flush
# Bestimmten Cache
./vendor/bin/typo3 cache:flush --group pagesIm Backend
Admin Tools → Maintenance → Flush CachesRedis-Cache
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['pages']['backend'] =
\TYPO3\CMS\Core\Cache\Backend\RedisBackend::class;
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['pages']['options'] = [
'hostname' => '127.0.0.1',
'port' => 6379,
'database' => 0,
];Backup
Datenbank-Backup
mysqldump -u typo3 -p typo3 > typo3-db-$(date +%Y%m%d).sqlKomplett-Backup
#!/bin/bash
DATE=$(date +%Y%m%d)
BACKUP_DIR="/backup/typo3"
mkdir -p $BACKUP_DIR
# Datenbank
mysqldump -u typo3 -pPASSWORD typo3 | gzip > $BACKUP_DIR/db-$DATE.sql.gz
# Dateien
tar -czf $BACKUP_DIR/files-$DATE.tar.gz \
/var/www/typo3/public/fileadmin \
/var/www/typo3/public/uploads \
/var/www/typo3/public/typo3conf
# Alte Backups löschen
find $BACKUP_DIR -type f -mtime +30 -deleteUpdate
Minor-Update
cd /var/www/typo3
composer update "typo3/*"
./vendor/bin/typo3 upgrade:run
./vendor/bin/typo3 cache:flushMajor-Update
# Backup erstellen!
# Composer.json anpassen: "typo3/cms-*": "^13.0"
composer update
# Upgrade-Wizard ausführen
./vendor/bin/typo3 upgrade:runSicherheit
Install Tool sichern
// Passwort ändern
Admin Tools → Settings → Change Install Tool PasswordTrusted Hosts
$GLOBALS['TYPO3_CONF_VARS']['SYS']['trustedHostsPattern'] =
'example\\.com|www\\.example\\.com';Benutzerrechte
System → Backend Users → Gruppen
→ Seitenzugriff einschränken
→ Tabellenzugriff einschränken
→ Module einschränkenSSL mit Let's Encrypt
apt install certbot python3-certbot-apache
certbot --apache -d example.com -d www.example.comSite-Config anpassen
# config.yaml
base: 'https://example.com/'Scheduler
Aufgabe einrichten
System → Scheduler → Add task
Klasse: TYPO3\CMS\Scheduler\Task\...
Typ: Recurring
Startzeit: ...
Intervall: 3600 (1 Stunde)Cron-Job
# /etc/cron.d/typo3
*/5 * * * * www-data /var/www/typo3/vendor/bin/typo3 scheduler:runTroubleshooting
Weißer Bildschirm
# Debug aktivieren
# AdditionalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['BE']['debug'] = true;
$GLOBALS['TYPO3_CONF_VARS']['SYS']['devIPmask'] = '*';
$GLOBALS['TYPO3_CONF_VARS']['SYS']['displayErrors'] = 1;500 Internal Server Error
# Apache-Log prüfen
tail -f /var/log/apache2/typo3_error.log
# TYPO3-Log
tail -f /var/www/typo3/var/log/typo3_*.logBerechtigungsprobleme
chown -R www-data:www-data /var/www/typo3
find /var/www/typo3 -type d -exec chmod 755 {} \;
find /var/www/typo3 -type f -exec chmod 644 {} \;
chmod -R 775 /var/www/typo3/var
chmod -R 775 /var/www/typo3/public/fileadminZusammenfassung
| Befehl | Funktion | |--------|----------| | typo3 cache:flush | Cache leeren | | typo3 upgrade:run | Upgrade-Wizard | | typo3 scheduler:run | Scheduler ausführen | | typo3 database:updateschema | Datenbank aktualisieren | | typo3 extension:list | Extensions auflisten |
| URL | Funktion | |-----|----------| | /typo3 | Backend | | /typo3/install.php | Install Tool |
Fazit
TYPO3 ist ein mächtiges Enterprise-CMS für komplexe Anforderungen. Die Installation mit Composer ist unkompliziert, die Konfiguration erfordert jedoch Einarbeitung. Die Kombination aus Backend-Administration und TypoScript bietet maximale Flexibilität. Für kleinere Projekte ist TYPO3 oft überdimensioniert – hier sind WordPress oder andere CMS die bessere Wahl.