# HTML sanitization

To prevent certain security exploits, Looker restricts which HTML tags, HTML tag attributes, and CSS properties are allowed in the [`html` parameter](https://docs.cloud.google.com/looker/docs/reference/param-field-html), in [custom welcome emails](https://docs.cloud.google.com/looker/docs/admin-panel-users-custom-welcome-email), and in [text tiles](https://docs.cloud.google.com/looker/docs/creating-user-defined-dashboards#adding_tiles_and_text_to_a_dashboard) and [tile notes](https://docs.cloud.google.com/looker/docs/editing-user-defined-dashboards#adding_a_tile_note) in dashboards.

Looker strips any HTML elements that aren't supported from the rendered HTML. For example, the following HTML has unsupported HTML tags:

    <div class="pretty"><badtag></badtag></div>

Looker will render this as:

    <div class="pretty"></div>

As another example, the following HTML has unsupported HTML attributes:

    <div class="pretty" badattr="uh-oh"></div>

Looker will render this as:

    <div class="pretty"></div>

HTML sanitization is on by default and can't be edited.


## Allowed HTML tags

Only certain HTML tags will be rendered in the browser. Any other tags will be stripped from rendered HTML.

Here is the list of HTML tags that Looker supports:
` a `

<br />

` abbr `

<br />

` acronym `

<br />

` address `

<br />

` area `

<br />

` article `

<br />

` aside `

<br />

` audio `

<br />

` b `

<br />

` bdi `

<br />

` bdo `

<br />

` big `

<br />

` blockquote `

<br />

` br `

<br />

` button `

<br />

` canvas `

<br />

` caption `

<br />

` center `

<br />

` cite `

<br />

` code `

<br />

` col `

<br />

` colgroup `

<br />

` datalist `

<br />

` dd `

<br />

` del `

<br />

` details `

<br />

` dfn `

<br />

` dir `

<br />

` div `

<br />

` dl `

<br />

` dt `

<br />

` em `

<br />

` fieldset `

<br />

` figcaption `

<br />

` footer `

<br />

` h1 `

<br />

` h2 `

<br />

` h3 `

<br />

` h4 `

<br />

` h5 `

<br />

` h6 `

<br />

` header `

<br />

` ins `

<br />

` hr `

<br />

` i `

<br />

` img `

<br />

` kbd `

<br />

` label `

<br />

` legend `

<br />

` li `

<br />

` map `

<br />

` mark `

<br />

` menu `

<br />

` meter `

<br />

` nav `

<br />

` ol `

<br />

` output `

<br />

` p `

<br />

` pre `

<br />

` progress `

<br />

` q `

<br />

` s `

<br />

` samp `

<br />

` section `

<br />

` small `

<br />

` source `

<br />

` span `

<br />

` strike `

<br />

` strong `

<br />

` sub `

<br />

` summary `

<br />

` sup `

<br />

` table `

<br />

` tbody `

<br />

` td `

<br />

` tfoot `

<br />

` th `

<br />

` thead `

<br />

` time `

<br />

` tr `

<br />

` track `

<br />

` tt `

<br />

` u `

<br />

` ul `

<br />

` var `

<br />

` video `

<br />


## Allowed HTML tag attributes

Only certain HTML attributes will be rendered in the browser. Any other attributes will be stripped from rendered HTML. This also applies to the CSS properties for HTML `style` tags.

Here is the list of HTML attributes that Looker supports:
` abbr `

<br />

` accept `

<br />

` accept-charset `

<br />

` accesskey `

<br />

` action `

<br />

` align `

<br />

` alt `

<br />

` autoplay `

<br />

` axis `

<br />

` border `

<br />

` cellpadding `

<br />

` cellspacing `

<br />

` char `

<br />

` charoff `

<br />

` charset `

<br />

` checked `

<br />

` cite `

<br />

` class `

<br />

` clear `

<br />

` color `

<br />

` cols `

<br />

` colspan `

<br />

` compact `

<br />

` controls `

<br />

` controlslist `

<br />

` coords `

<br />

` datetime `

<br />

` dir `

<br />

` disabled `

<br />

` enctype `

<br />

` for `

<br />

` frame `

<br />

` headers `

<br />

` height `

<br />

` href `

<br />

` hreflang `

<br />

` hspace `

<br />

` id `

<br />

` ismap `

<br />

` label `

<br />

` lang `

<br />

` longdesc `

<br />

` loop `

<br />

` loopcount `

<br />

` loopend `

<br />

` loopstart `

<br />

` maxlength `

<br />

` media `

<br />

` method `

<br />

` multiple `

<br />

` muted `

<br />

` name `

<br />

` nohref `

<br />

` noshade `

<br />

` nowrap `

<br />

` poster `

<br />

` preload `

<br />

` prompt `

<br />

` readonly `

<br />

` rel `

<br />

` rev `

<br />

` rows `

<br />

` rowspan `

<br />

` rules `

<br />

` scope `

<br />

` selected `

<br />

` shape `

<br />

` size `

<br />

` span `

<br />

` src `

<br />

` start `

<br />

` style `

<br />

` summary `

<br />

` tabindex `

<br />

` target `

<br />

` title `

<br />

` type `

<br />

` usemap `

<br />

` valign `

<br />

` value `

<br />

` vspace `

<br />

` width `

<br />

` xml:lang `

<br />


## Allowed CSS Properties for HTML `style` Tags

Here is the list of allowed CSS properties that Looker supports:
` -moz-border-radius `

<br />

` -moz-border-radius-bottomleft `

<br />

` -moz-border-radius-bottomright `

<br />

` -moz-border-radius-topleft `

<br />

` -moz-border-radius-topright `

<br />

` -moz-box-shadow `

<br />

` -moz-outline `

<br />

` -moz-outline-color `

<br />

` -moz-outline-style `

<br />

` -moz-outline-width `

<br />

` -o-text-overflow `

<br />

` -webkit-border-bottom-left-radius `

<br />

` -webkit-border-bottom-right-radius `

<br />

` -webkit-border-radius `

<br />

` -webkit-border-radius-bottom-left `

<br />

` -webkit-border-radius-bottom-right `

<br />

` -webkit-border-radius-top-left `

<br />

` -webkit-border-radius-top-right `

<br />

` -webkit-border-top-left-radius `

<br />

` -webkit-border-top-right-radius `

<br />

` -webkit-box-shadow `

<br />

` azimuth `

<br />

` background `

<br />

` background-attachment `

<br />

` background-color `

<br />

` background-image` (note that `url` is unsupported)

<br />

` background-position `

<br />

` background-repeat `

<br />

` border `

<br />

` border-bottom `

<br />

` border-bottom-color `

<br />

` border-bottom-left-radius `

<br />

` border-bottom-right-radius `

<br />

` border-bottom-style `

<br />

` border-bottom-width `

<br />

` border-collapse `

<br />

` border-color `

<br />

` border-left `

<br />

` border-left-color `

<br />

` border-left-style `

<br />

` border-left-width `

<br />

` border-radius `

<br />

` border-right `

<br />

` border-right-color `

<br />

` border-right-style `

<br />

` border-right-width `

<br />

` border-spacing `

<br />

` border-style `

<br />

` border-top `

<br />

` border-top-color `

<br />

` border-top-left-radius `

<br />

` border-top-right-radius `

<br />

` border-top-style `

<br />

` border-top-width `

<br />

` border-width `

<br />

` box-shadow `

<br />

` caption-side `

<br />

` clear `

<br />

` color `

<br />

` cue `

<br />

` cue-after `

<br />

` cue-before `

<br />

` cursor `

<br />

` direction `

<br />

` display `

<br />

` elevation `

<br />

` empty-cells `

<br />

` float `

<br />

` font `

<br />

` font-family `

<br />

` font-size `

<br />

` font-stretch `

<br />

` font-style `

<br />

` font-variant `

<br />

` font-weight `

<br />

` height `

<br />

` image() `

<br />

` letter-spacing `

<br />

` line-height `

<br />

` linear-gradient() `

<br />

` list-style `

<br />

` list-style-image `

<br />

` list-style-position `

<br />

` list-style-type `

<br />

` margin `

<br />

` margin-bottom `

<br />

` margin-left `

<br />

` margin-right `

<br />

` margin-top `

<br />

` max-height `

<br />

` max-width `

<br />

` min-height `

<br />

` min-width `

<br />

` outline `

<br />

` outline-color `

<br />

` outline-style `

<br />

` outline-width `

<br />

` overflow `

<br />

` padding `

<br />

` padding-bottom `

<br />

` padding-left `

<br />

` padding-right `

<br />

` padding-top `

<br />

` pause `

<br />

` pause-after `

<br />

` pause-before `

<br />

` pitch `

<br />

` pitch-range `

<br />

` quotes `

<br />

` radial-gradient() `

<br />

` rect() `

<br />

` repeating-linear-gradient() `

<br />

` repeating-radial-gradient() `

<br />

` rgb() `

<br />

` rgba() `

<br />

` richness `

<br />

` speak `

<br />

` speak-header `

<br />

` speak-numeral `

<br />

` speak-punctuation `

<br />

` speech-rate `

<br />

` stress `

<br />

` table-layout `

<br />

` text-align `

<br />

` text-decoration `

<br />

` text-indent `

<br />

` text-overflow `

<br />

` text-shadow `

<br />

` text-transform `

<br />

` text-wrap `

<br />

` unicode-bidi `

<br />

` vertical-align `

<br />

` voice-family `

<br />

` volume `

<br />

` white-space `

<br />

` width `

<br />

` word-spacing `

<br />

` word-wrap `

<br />