HTML | <link> media Attribute Last Updated : 06 Jun, 2022 Comments Improve Suggest changes Like Article Like Report The HTML link media attribute is used to specify what media/device the target resource is optimized for. This attribute used to specify a different style for different media type. The media attribute can accept several values. Syntax: <link media="value"> Possible Operators: ValueDescriptionandAND operatornotNOT operator,OR operator Devices: ValueDescriptionallSuitable for all devicesauralSpeech synthesizersbrailleBraille feedback deviceshandheldHandheld devices (small screen, limited bandwidth)projectionProjectorsprintPrint preview mode/printed pagesscreenComputer screensttyTeletypes and similar media using a fixed-pitch character gridtvLow resolution or limited scroll ability type devices like Television. Values: ValueDescriptionwidthTargeted display area’s width.heightTargeted display area’s heightdevice-widthTarget display or paper’s width.device-heightTarget display or paper’s height.orientationTarget display or paper’s orientation.aspect-ratioWidth/height ratio of the targeted display area.device-aspect-ratioDevice-width/device-height ratio of the target display/paper.colorBits per color of target display.color-indexNumber of colors the target display can handle.monochromeBits per pixel in a monochrome frame buffer.resolutionPixel density (dpi or dpcm) of the target display/paper.scanScanning method of a tv display.gridIf the output device is grid or bitmap. Note: Prefixes like "min-" and "max-" can be used. Example: html <!DOCTYPE html> <html> <head> <link rel="stylesheet" type="text/css" href="index_screen.css"> <link rel="stylesheet" type="text/css" href="index_print.css" media="print"> </head> <body> <center> <h1>GeeksforGeeks</h1> <p><a href="index.html" target="_blank"> Click here </a> </center> </body> </html> Output: Supported Browsers: The browsers supported by HTML link media attribute are listed below: Google Chrome 1 and aboveEdge 12 and aboveInternet Explorer 6 and aboveFirefox 1 and aboveApple Safari 4 and aboveOpera 12.1 and above Comment More infoAdvertise with us Next Article HTML | media Attribute V Vijay Sirra Follow Improve Article Tags : Web Technologies HTML HTML-Attributes Similar Reads HTML | <a> media Attribute The HTML <a> media attribute specifies the media or device the linked document is optimized for. This attribute specifies that the target URL is designed for devices like iPhone, speech or print media. This attribute can accept several values. This can be used only if the href attribute is pre 2 min read HTML | <a> media Attribute The HTML <a> media attribute specifies the media or device the linked document is optimized for. This attribute specifies that the target URL is designed for devices like iPhone, speech or print media. This attribute can accept several values. This can be used only if the href attribute is pre 2 min read HTML | <area> media Attribute The HTML area media attribute is used to specify the media or device the target URL is optimized for. this attribute specify the style is for specific devices like print media or speech. This attribute can accept several values. Only used if the href attribute is present. This attribute is purely ad 2 min read HTML | <style> media Attribute The HTML style media attribute is used to specify the media or device the CSS style is optimized for. this attribute specify the style is for specific devices like print media or speech. This attribute can accept several values. Syntax:<style media="value">Possible Operators:ValueDescriptionan 2 min read HTML | <style> media Attribute The HTML style media attribute is used to specify the media or device the CSS style is optimized for. this attribute specify the style is for specific devices like print media or speech. This attribute can accept several values. Syntax:<style media="value">Possible Operators:ValueDescriptionan 2 min read HTML | <source> media Attribute The HTML source media attribute accepts any valid media query that would normally be defined in a CSS. This attribute can accept several values. Syntax: <source media="media_query"> Possible Operators: Value Description and AND operator not NOT operator , OR operator Devices: Value Description 2 min read Like