PHP get class name without namespace The fastest way (performance-wise) to do that is to use ReflectionClass.