Title: oembed_linktypes
Published: April 25, 2014
Last modified: April 28, 2025

---

# apply_filters( ‘oembed_linktypes’, string[] $format )

## In this article

 * [Parameters](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#wp--skip-link--target)

Filters the link types that contain oEmbed provider URLs.

## 󠀁[Parameters](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#parameters)󠁿

 `$format`string[]

Array of oEmbed link types. Accepts `'application/json+oembed'`, `'text/xml+oembed'`,
and `'application/xml+oembed'` (incorrect, used by at least Vimeo).

## 󠀁[Source](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#source)󠁿

    ```php
    $linktypes = apply_filters(
    	'oembed_linktypes',
    	array(
    		'application/json+oembed' => 'json',
    		'text/xml+oembed'         => 'xml',
    		'application/xml+oembed'  => 'xml',
    	)
    );
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/class-wp-oembed.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/6.9.4/src/wp-includes/class-wp-oembed.php#L473)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/6.9.4/src/wp-includes/class-wp-oembed.php#L473-L480)

## 󠀁[Related](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#related)󠁿

| Used by | Description | 
| [WP_oEmbed::discover()](https://developer.wordpress.org/reference/classes/wp_oembed/discover/)`wp-includes/class-wp-oembed.php` |

Attempts to discover link tags at the given URL for an oEmbed provider.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/hooks/oembed_linktypes/?output_format=md#changelog)󠁿

| Version | Description | 
| [2.9.0](https://developer.wordpress.org/reference/since/2.9.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Foembed_linktypes%2F)
before being able to contribute a note or feedback.