In PHP, strlen(), STRLEN() and StrLen() all call the same function, and class and method names work the same way. Variables, constants and properties are already case-sensitive, so the rules are mixed. This RFC from Jorg Sowa proposed making function, method, class and namespace names case-sensitive too, in two steps.

Show me

Here is part of the RFC's example of what works today:

strlen("hello");    // canonical
STRLEN("hello");    // works
StrLen("hello");    // also works

new UserService();  // canonical
new USERSERVICE();  // works
new userservice();  // also works

The two steps

  • PHP 8.6: Wrong case still works, but PHP emits an E_DEPRECATED notice.
  • Next major version: Wrong case becomes a fatal error.

The deprecation would show up in a lot of places, including calls, new, instanceof, type declarations, extends, implements, use imports, catch blocks and namespace declarations. It also covers functions that take a class name as a string, like class_exists(), method_exists() and the Reflection classes. Magic methods declared with the wrong case, like __CONSTRUCT, count too.

Some things wouldn't change. Keywords like if and class stay case-insensitive, and so do built-in type names like int, along with self, parent, static, true, false and null.

Only ASCII letters are affected. Names with other letters, like Ñoño, are already case-sensitive today.

What it means for existing code

The RFC scanned ten popular projects, including Laravel, Symfony and WordPress. Seven had no wrong-case references, and the other three had 37 hits in 3 files, all in tests, old bundled code or tooling scripts.

Serialized data is the bigger concern. If stored data contains a class name in the wrong case, unserialize() would emit the notice for every row, and fixing that means migrating the data, not just the code.

Tools like PHPStan, PHP-CS-Fixer and PhpStorm can already flag wrong-case references.

Where it stands

The author withdrew the RFC. It's dated June 1, 2026, and had two votes planned, one for the deprecation and one for the fatal error, but no one voted. The page doesn't say why it was withdrawn.