HTML <object> data Attribute

Definition and Usage

data Attribute specifies the URL of the resource to be used by the object.

Example

How to Embed Images Using the <object> Element:

<object data="tulip-yellow.jpg" width="600" height="400"></object>

Try It Yourself

Syntax

<object data="URL">

Attribute Value

Value Description
URL

Specifies the URL of the resource to be used by the object.

Possible Values:

  • Absolute URL - Points to data on another website (e.g., href="http://www.example.com/images/pic_trulli.jpg")
  • Relative URL - Points to data within a website (e.g., href="pic_trulli.jpg")

Browser Support

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
Support Support Support Support Support