---
title: "Deprecation: #110202 - StringUtility::multibyteStringPad() method"
manual: "TYPO3 Core Changelog"
version: "main"
permalink: "https://docs.typo3.org/permalink/changelog:deprecation-110202-1784146595"
source: "Changelog/15.0/Deprecation-110202-StringUtilityMultibyteStringPad.rst"
modified: "2026-09-15T10:46:36+00:00"
---

# Deprecation: #110202 - StringUtility::multibyteStringPad() method

See [forge#110202](https://forge.typo3.org/issues/110202)

## Description

The method `\TYPO3\CMS\Core\Utility\StringUtility::multibyteStringPad()`
has been marked as deprecated and will be removed in TYPO3 v16.0.

The method was introduced to provide a multibyte-safe variant of PHP's
`str_pad()`. Since PHP 8.3, the native function `mb_str_pad()`
covers exactly this use case, making the TYPO3 wrapper obsolete.

## Impact

Calling the method will trigger a PHP deprecation warning. It will continue
to work as before until it is removed in TYPO3 v16.0.

## Affected installations

TYPO3 installations with custom extensions or code that directly call
`StringUtility::multibyteStringPad()` are affected.

The extension scanner will report any usage as a **strong match**.

## Migration

Use the native PHP function `mb_str_pad()` instead.

Note that `mb_str_pad()` throws a `\ValueError` when an empty pad
string is passed, whereas `StringUtility::multibyteStringPad()` returned
the input unchanged. If an empty pad string can occur, guard against it.

**Before (deprecated)**

```php
use TYPO3\CMS\Core\Utility\StringUtility;

$padded = StringUtility::multibyteStringPad($string, 10, $padString, STR_PAD_LEFT);
```

**After (recommended)**

```php
$padded = $padString === ''
    ? $string
    : mb_str_pad($string, 10, $padString, STR_PAD_LEFT);
```
