WordPress from url get external source title

Here you go:

class UrlToTitleConverter{

    public function convert($Url){
        $response = wp_remote_get($Url);
        if ( is_array( $response ) ) {
            $body = $response['body'];
            $title = substr($body, strpos($body, '<title>')+7);
            $title = substr($title, 0, strpos($title, '</title>'));
        }
        return $title;
    }
}