Performance Issues
Solutions for performance problems, slow loading, and optimization strategies.
Table of Contents
Editor Performance
Issue: Slow Editor Loading
Symptoms:
- CKEditor takes long time to initialize
- Image browser slow to open
Causes:
- Large number of files in file browser
- Unoptimized image processing settings
- Network latency
- Browser resource constraints
Solutions:
- Optimize Image Processing:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['GFX']['jpg_quality'] = 85;
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_effects'] = false; // If not needed
- Reduce Maximum Dimensions:
RTE.default.buttons.image.options.magic {
maxWidth = 1200 # Instead of 1920
maxHeight = 800 # Instead of 9999
}
- Limit File Browser Results:
Configure file mounts to show only relevant directories:
# User TSConfig
options.folderTree.uploadFieldsInLinkBrowser = 0
options.pageTree.showPageIdWithTitle = 0
Tip
Reducing maximum dimensions can significantly improve editor performance.
Issue: Image Selection Dialog Slow
Symptoms:
- Modal takes long time to open
- Thumbnails load slowly
- Browser becomes unresponsive
Causes:
- Too many files in directory
- Large unprocessed images
- Missing thumbnail cache
Solutions:
-
Organize Files into Subdirectories:
- Group images by category
- Use year/month folder structure
- Keep directories under 100 files
- Pre-generate Thumbnails:
# Generate missing thumbnails
./vendor/bin/typo3 cleanup:missingfiles
./vendor/bin/typo3 cleanup:previewlinks
- Optimize File Storage:
# Limit file selection to specific folders
options.defaultUploadFolder = 1:fileadmin/user_upload/
Frontend Performance
Issue: Slow Page Load Due to Images
Symptoms:
- Pages load slowly
- Large images not processed
- High bandwidth usage
Causes:
- Original large images served instead of processed versions
- No image compression
- Missing lazy loading
- Too many images on page
Solutions:
- Enable Image Processing:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['GFX'] = [
'processor_enabled' => true,
'processor' => 'ImageMagick',
'jpg_quality' => 85,
];
- Configure Reasonable Maximum Dimensions:
RTE.default.buttons.image.options.magic {
maxWidth = 1920
maxHeight = 1080
}
- Implement Lazy Loading:
lib.parseFunc_RTE.tags.img {
current = 1
preUserFunc = Netresearch\RteCKEditorImage\Controller\ImageRenderingController->renderImageAttributes
stdWrap.replacement {
10 {
search = <img
replace = <img loading="lazy"
}
}
}
- Enable Browser Caching:
# .htaccess
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType image/webp "access plus 1 year"
</IfModule>
Issue: Excessive Bandwidth Usage
Symptoms:
- High server bandwidth consumption
- Slow site on mobile devices
- Large page sizes
Solutions:
- Use WebP Format:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_allowUpscaling'] = false;
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_stripColorProfileByDefault'] = true;
- Implement Progressive JPEG:
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_interlace'] = true;
- Compress Images:
$GLOBALS['TYPO3_CONF_VARS']['GFX']['jpg_quality'] = 80;
Image Processing Performance
Issue: Image Processing Timeouts
Symptoms:
- 500 errors when uploading images
- Processing hangs
- Timeouts in backend
Causes:
- Insufficient PHP memory
- Low execution time limits
- Slow image processor
- Very large source images
Solutions:
- Increase PHP Limits:
// php.ini or LocalConfiguration.php
memory_limit = 512M
max_execution_time = 300
upload_max_filesize = 20M
post_max_size = 20M
- Optimize Image Processor:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_path_lzw'] = '';
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_colorspace'] = 'RGB';
- Limit Upload Size:
# Page TSConfig
RTE.default.buttons.image.options.magic {
maxFileSize = 5000 # 5MB in KB
}
Issue: Processed Images Directory Growing
Symptoms:
- Large
_processed_/
directory - Disk space issues
- Duplicate processed images
Causes:
- Old processed images not cleaned up
- Multiple versions of same image
- Unused processed files accumulating
Solutions:
- Clean Old Processed Files:
# Remove processed files older than 30 days
find fileadmin/_processed_ -type f -mtime +30 -delete
- Implement Automated Cleanup:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_allowTemporaryMasksAsPng'] = false;
- Schedule Cleanup Task:
Create a scheduler task to regularly clean old processed images:
# Cron job example (runs weekly)
0 2 * * 0 find /path/to/fileadmin/_processed_ -type f -mtime +30 -delete
Database Performance
Issue: Large Database Size
Symptoms:
- Database growing rapidly
- sys_refindex table very large
- Slow queries
Causes:
- Excessive soft reference entries
- Orphaned records
- Unoptimized indexes
Solutions:
- Rebuild Reference Index:
./vendor/bin/typo3 referenceindex:update
- Clean Up Orphaned Records:
-- Find images in deleted content
SELECT uid, bodytext
FROM tt_content
WHERE deleted = 1 AND bodytext LIKE '%data-htmlarea-file-uid%';
- Optimize Tables:
OPTIMIZE TABLE sys_refindex;
OPTIMIZE TABLE tt_content;
Issue: Slow Reference Index Updates
Symptoms:
- Reference index update takes long time
- High CPU usage during updates
Solutions:
- Batch Update References:
# Update in smaller batches
./vendor/bin/typo3 referenceindex:update --check
- Schedule Off-Peak Updates:
Run reference index updates during low-traffic periods:
# Cron job (runs at 3 AM)
0 3 * * * /path/to/vendor/bin/typo3 referenceindex:update
Cache Performance
Issue: Excessive Cache Invalidation
Symptoms:
- Caches cleared too frequently
- Slow page regeneration
- High server load
Causes:
- Aggressive cache clearing
- Content changes trigger full cache clear
- Misconfigured cache tags
Solutions:
- Optimize Cache Configuration:
// LocalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['pages'] = [
'backend' => \TYPO3\CMS\Core\Cache\Backend\RedisBackend::class,
'options' => [
'hostname' => 'localhost',
'database' => 0,
'port' => 6379,
],
];
- Use Cache Tags Effectively:
config {
cache_period = 86400
sendCacheHeaders = 1
}
- Implement Selective Cache Clearing:
# Clear only specific cache groups
./vendor/bin/typo3 cache:flush --group=pages
Network Performance
Issue: Slow Image Loading from CDN
Symptoms:
- Images load slowly despite CDN
- Inconsistent loading times
- Failed CDN requests
Solutions:
- Configure Proper CDN:
config {
absRefPrefix = /
baseURL = https://cdn.yourdomain.com/
}
- Use HTTP/2:
Ensure your server supports HTTP/2 for multiplexing
- Implement Preconnect:
<link rel="preconnect" href="https://cdn.yourdomain.com">
<link rel="dns-prefetch" href="https://cdn.yourdomain.com">
Monitoring and Profiling
Performance Monitoring
- Enable TYPO3 Admin Panel:
config.admPanel = 1
- Monitor Image Processing:
# Check processing time
./vendor/bin/typo3 backend:test:imageprocessing
- Track Page Load Times:
- Use browser DevTools Network tab to monitor:
-
- Image load times
- TTFB (Time to First Byte)
- Total page load time
Database Query Profiling
-- Find slow queries
SHOW PROCESSLIST;
-- Analyze reference index queries
EXPLAIN SELECT * FROM sys_refindex WHERE tablename='tt_content';
Image Processing Profiling
# Time image processing
time ./vendor/bin/typo3 backend:test:imageprocessing
# Monitor processed files
watch -n 5 "ls -lh fileadmin/_processed_/ | wc -l"
Optimization Best Practices
Image Optimization Checklist
✓ Configure reasonable maximum dimensions:
RTE.default.buttons.image.options.magic {
maxWidth = 1920
maxHeight = 1080
}
✓ Enable image processing:
$GLOBALS['TYPO3_CONF_VARS']['GFX']['processor_enabled'] = true;
✓ Set appropriate JPEG quality:
$GLOBALS['TYPO3_CONF_VARS']['GFX']['jpg_quality'] = 85;
✓ Implement lazy loading:
<img loading="lazy" src="..." />
✓ Use browser caching:
ExpiresActive On
ExpiresByType image/jpeg "access plus 1 year"
✓ Regular cleanup of processed files:
find fileadmin/_processed_ -type f -mtime +30 -delete
✓ Monitor disk space and database size
✓ Optimize images before upload (recommend to editors)
Server Optimization Checklist
✓ Adequate PHP memory: 512M minimum
✓ Fast image processor: ImageMagick or GraphicsMagick
✓ Redis/Memcached for caching
✓ HTTP/2 support enabled
✓ CDN for static assets
✓ Regular database optimization
✓ Scheduled cleanup tasks
Getting Help
If issues persist after troubleshooting:
- Check GitHub Issues: https://github.com/netresearch/t3x-rte_ckeditor_image/issues
- Review Changelog: Look for performance improvements in CHANGELOG.md
- TYPO3 Slack: Join #typo3-cms
- Stack Overflow: Tag questions with
typo3
andperformance
Important
When reporting performance issues, include:
- TYPO3 version
- Extension version
- PHP version and limits
- Server specifications
- Database size
- Number of images
- Performance measurements
- Profiling data